Class: Shrine::Plugins::DownloadEndpoint::FileUrl
- Inherits:
-
Object
- Object
- Shrine::Plugins::DownloadEndpoint::FileUrl
- Defined in:
- lib/shrine/plugins/download_endpoint.rb
Instance Attribute Summary collapse
-
#file ⇒ Object
readonly
Returns the value of attribute file.
Instance Method Summary collapse
- #call(host: self.host) ⇒ Object
-
#initialize(file) ⇒ FileUrl
constructor
A new instance of FileUrl.
Constructor Details
#initialize(file) ⇒ FileUrl
Returns a new instance of FileUrl.
64 65 66 |
# File 'lib/shrine/plugins/download_endpoint.rb', line 64 def initialize(file) @file = file end |
Instance Attribute Details
#file ⇒ Object (readonly)
Returns the value of attribute file.
62 63 64 |
# File 'lib/shrine/plugins/download_endpoint.rb', line 62 def file @file end |
Instance Method Details
#call(host: self.host) ⇒ Object
68 69 70 |
# File 'lib/shrine/plugins/download_endpoint.rb', line 68 def call(host: self.host) [host, *prefix, path].join("/") end |