Class: Paperclip::S3DU::S3DirectUpload
- Inherits:
-
Object
- Object
- Paperclip::S3DU::S3DirectUpload
- Defined in:
- lib/paperclip_s3du/s3_direct_upload.rb
Instance Attribute Summary collapse
-
#content_type ⇒ Object
readonly
Returns the value of attribute content_type.
-
#fingerprint ⇒ Object
readonly
Returns the value of attribute fingerprint.
-
#path ⇒ Object
readonly
Returns the value of attribute path.
-
#size ⇒ Object
readonly
Returns the value of attribute size.
Instance Method Summary collapse
-
#initialize(hash = {}) ⇒ S3DirectUpload
constructor
A new instance of S3DirectUpload.
- #original_filename ⇒ Object
Constructor Details
#initialize(hash = {}) ⇒ S3DirectUpload
Returns a new instance of S3DirectUpload.
6 7 8 9 10 11 |
# File 'lib/paperclip_s3du/s3_direct_upload.rb', line 6 def initialize hash = {} @path = hash[:file_path] @size = hash[:file_size] @content_type = hash[:content_type] @fingerprint = hash[:fingerprint] end |
Instance Attribute Details
#content_type ⇒ Object (readonly)
Returns the value of attribute content_type.
4 5 6 |
# File 'lib/paperclip_s3du/s3_direct_upload.rb', line 4 def content_type @content_type end |
#fingerprint ⇒ Object (readonly)
Returns the value of attribute fingerprint.
4 5 6 |
# File 'lib/paperclip_s3du/s3_direct_upload.rb', line 4 def fingerprint @fingerprint end |
#path ⇒ Object (readonly)
Returns the value of attribute path.
4 5 6 |
# File 'lib/paperclip_s3du/s3_direct_upload.rb', line 4 def path @path end |
#size ⇒ Object (readonly)
Returns the value of attribute size.
4 5 6 |
# File 'lib/paperclip_s3du/s3_direct_upload.rb', line 4 def size @size end |
Instance Method Details
#original_filename ⇒ Object
13 14 15 |
# File 'lib/paperclip_s3du/s3_direct_upload.rb', line 13 def original_filename File.basename @path end |