Class: Basecamp::DownloadResult
- Inherits:
-
Data
- Object
- Data
- Basecamp::DownloadResult
- Defined in:
- lib/basecamp/download_result.rb
Overview
Result of downloading file content from a URL.
Instance Attribute Summary collapse
-
#body ⇒ Object
readonly
Returns the value of attribute body.
-
#content_length ⇒ Object
readonly
Returns the value of attribute content_length.
-
#content_type ⇒ Object
readonly
Returns the value of attribute content_type.
-
#filename ⇒ Object
readonly
Returns the value of attribute filename.
Instance Method Summary collapse
-
#initialize(body:, content_type: "", content_length: -1,, filename: "download") ⇒ DownloadResult
constructor
A new instance of DownloadResult.
Constructor Details
#initialize(body:, content_type: "", content_length: -1,, filename: "download") ⇒ DownloadResult
Returns a new instance of DownloadResult.
6 7 8 |
# File 'lib/basecamp/download_result.rb', line 6 def initialize(body:, content_type: "", content_length: -1, filename: "download") super end |
Instance Attribute Details
#body ⇒ Object (readonly)
Returns the value of attribute body
5 6 7 |
# File 'lib/basecamp/download_result.rb', line 5 def body @body end |
#content_length ⇒ Object (readonly)
Returns the value of attribute content_length
5 6 7 |
# File 'lib/basecamp/download_result.rb', line 5 def content_length @content_length end |
#content_type ⇒ Object (readonly)
Returns the value of attribute content_type
5 6 7 |
# File 'lib/basecamp/download_result.rb', line 5 def content_type @content_type end |
#filename ⇒ Object (readonly)
Returns the value of attribute filename
5 6 7 |
# File 'lib/basecamp/download_result.rb', line 5 def filename @filename end |