Class: Fabychy::DataTypes::ImageAttachment
- Inherits:
-
Attachment
- Object
- Base
- Attachment
- Fabychy::DataTypes::ImageAttachment
- Defined in:
- lib/fabychy/data_types/image_attachment.rb
Instance Method Summary collapse
-
#initialize(*params) ⇒ ImageAttachment
constructor
A new instance of ImageAttachment.
- #validations ⇒ Object
Constructor Details
#initialize(*params) ⇒ ImageAttachment
Returns a new instance of ImageAttachment.
6 7 8 9 |
# File 'lib/fabychy/data_types/image_attachment.rb', line 6 def initialize *params super(*params) @type = 'image' end |
Instance Method Details
#validations ⇒ Object
11 12 13 14 15 16 17 |
# File 'lib/fabychy/data_types/image_attachment.rb', line 11 def validations super.merge( { payload: {required: true, class: [ImagePayload] } } ) end |