class Rev::Attachment
Represents order attachment - logical document associated with order
Constants
- KINDS
- REPRESENTATIONS
List of supported mime-types used to request attachment's content within 'Accept' header
Attributes
audio_length_seconds[R]
id[R]
kind[R]
links[R]
name[R]
video_length_seconds[R]
Public Class Methods
new(fields)
click to toggle source
@param fields [Hash] fields of attachment fields parsed from JSON API response
Calls superclass method
Rev::ApiSerializable::new
# File lib/rev-api/models/order.rb, line 102 def initialize(fields) super fields @links = fields['links'].map { |link_fields| Link.new(link_fields) } end
representation_mime(ext)
click to toggle source
@param ext [Symbol] extension @return [String] mime-type for requested extension
# File lib/rev-api/models/order.rb, line 109 def self.representation_mime(ext) REPRESENTATIONS[ext] end