Class: E621ExportDownloader::ExportHelper
- Inherits:
-
Object
- Object
- E621ExportDownloader::ExportHelper
- Extended by:
- T::Generic, T::Sig
- Defined in:
- lib/e621_export_downloader/export_helper.rb
Constant Summary collapse
- Model =
type_member
Instance Attribute Summary collapse
-
#client ⇒ Object
readonly
Returns the value of attribute client.
-
#type ⇒ Object
readonly
Returns the value of attribute type.
Instance Method Summary collapse
- #delete ⇒ Object
- #download ⇒ Object
- #exists? ⇒ Boolean
- #get ⇒ Object
-
#initialize(type:, client:) ⇒ ExportHelper
constructor
A new instance of ExportHelper.
- #read(&block) ⇒ Object
- #read_all ⇒ Object
Constructor Details
#initialize(type:, client:) ⇒ ExportHelper
Returns a new instance of ExportHelper.
18 19 20 21 22 |
# File 'lib/e621_export_downloader/export_helper.rb', line 18 def initialize(type:, client:) @type = type @client = client @_get = T.let(nil, T.nilable(Export[Model])) end |
Instance Attribute Details
#client ⇒ Object (readonly)
Returns the value of attribute client.
15 16 17 |
# File 'lib/e621_export_downloader/export_helper.rb', line 15 def client @client end |
#type ⇒ Object (readonly)
Returns the value of attribute type.
12 13 14 |
# File 'lib/e621_export_downloader/export_helper.rb', line 12 def type @type end |
Instance Method Details
#delete ⇒ Object
25 26 27 |
# File 'lib/e621_export_downloader/export_helper.rb', line 25 def delete _get.delete end |
#download ⇒ Object
30 31 32 |
# File 'lib/e621_export_downloader/export_helper.rb', line 30 def download _get.download end |
#exists? ⇒ Boolean
35 36 37 |
# File 'lib/e621_export_downloader/export_helper.rb', line 35 def exists? _get.exists? end |
#get ⇒ Object
40 41 42 |
# File 'lib/e621_export_downloader/export_helper.rb', line 40 def get _get end |
#read(&block) ⇒ Object
45 46 47 |
# File 'lib/e621_export_downloader/export_helper.rb', line 45 def read(&block) _get.read(&block) end |
#read_all ⇒ Object
50 51 52 |
# File 'lib/e621_export_downloader/export_helper.rb', line 50 def read_all _get.read_all end |