Class: MailAttachmentUploader::MimeIO
- Inherits:
-
StringIO
- Object
- StringIO
- MailAttachmentUploader::MimeIO
- Defined in:
- lib/generators/mastiff/install/templates/carrierwave/mail_attachment_uploader.rb
Instance Attribute Summary collapse
-
#filepath ⇒ Object
Returns the value of attribute filepath.
Instance Method Summary collapse
-
#initialize(*args) ⇒ MimeIO
constructor
A new instance of MimeIO.
- #original_filename ⇒ Object
Constructor Details
#initialize(*args) ⇒ MimeIO
Returns a new instance of MimeIO.
10 11 12 13 |
# File 'lib/generators/mastiff/install/templates/carrierwave/mail_attachment_uploader.rb', line 10 def initialize(*args) super(*args[1..-1]) @filepath = args[0] end |
Instance Attribute Details
#filepath ⇒ Object
Returns the value of attribute filepath.
8 9 10 |
# File 'lib/generators/mastiff/install/templates/carrierwave/mail_attachment_uploader.rb', line 8 def filepath @filepath end |
Instance Method Details
#original_filename ⇒ Object
15 16 17 |
# File 'lib/generators/mastiff/install/templates/carrierwave/mail_attachment_uploader.rb', line 15 def original_filename File.basename(@filepath) end |