Class: ActiveStorageValidations::ASVAttachableAdapter::Uploaded
- Inherits:
-
Base
- Object
- Base
- ActiveStorageValidations::ASVAttachableAdapter::Uploaded
show all
- Defined in:
- lib/active_storage_validations/asv_attachable_adapter.rb
Instance Method Summary
collapse
Methods inherited from Base
#initialize
Instance Method Details
#content_type ⇒ Object
129
130
131
|
# File 'lib/active_storage_validations/asv_attachable_adapter.rb', line 129
def content_type
@attachable.content_type
end
|
#filename ⇒ Object
133
134
135
|
# File 'lib/active_storage_validations/asv_attachable_adapter.rb', line 133
def filename
@attachable.original_filename
end
|
#read(max_byte_size: nil) ⇒ Object
137
138
139
|
# File 'lib/active_storage_validations/asv_attachable_adapter.rb', line 137
def read(max_byte_size: nil)
read_from(@attachable, max_byte_size)
end
|
#rewind ⇒ Object
141
142
143
|
# File 'lib/active_storage_validations/asv_attachable_adapter.rb', line 141
def rewind
@attachable.rewind
end
|
145
146
147
|
# File 'lib/active_storage_validations/asv_attachable_adapter.rb', line 145
def with_media_path(_tempfile)
yield @attachable.path
end
|