Module: Shrine::UploadedFile::ClassMethods
- Included in:
- Shrine::UploadedFile
- Defined in:
- lib/shrine/uploaded_file.rb
Instance Attribute Summary collapse
-
#shrine_class ⇒ Object
Returns the Shrine class that this file class is namespaced under.
Instance Method Summary collapse
-
#inspect ⇒ Object
Since UploadedFile is anonymously subclassed when Shrine is subclassed, and then assigned to a constant of the Shrine subclass, make inspect reflect the likely name for the class.
Instance Attribute Details
#shrine_class ⇒ Object
Returns the Shrine class that this file class is namespaced under.
14 15 16 |
# File 'lib/shrine/uploaded_file.rb', line 14 def shrine_class @shrine_class end |
Instance Method Details
#inspect ⇒ Object
Since UploadedFile is anonymously subclassed when Shrine is subclassed, and then assigned to a constant of the Shrine subclass, make inspect reflect the likely name for the class.
19 20 21 |
# File 'lib/shrine/uploaded_file.rb', line 19 def inspect "#{shrine_class.inspect}::UploadedFile" end |