Class: Io::Flow::V0::Models::GenericReservationError
- Inherits:
-
ReservationError
- Object
- ReservationError
- Io::Flow::V0::Models::GenericReservationError
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Instance Attribute Summary collapse
-
#messages ⇒ Object
readonly
Returns the value of attribute messages.
Attributes inherited from ReservationError
Instance Method Summary collapse
- #copy(incoming = {}) ⇒ Object
-
#initialize(incoming = {}) ⇒ GenericReservationError
constructor
A new instance of GenericReservationError.
- #subtype_to_hash ⇒ Object
- #to_json ⇒ Object
Methods inherited from ReservationError
Constructor Details
#initialize(incoming = {}) ⇒ GenericReservationError
24349 24350 24351 24352 24353 24354 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 24349 def initialize(incoming={}) super(:code => ReservationError::Types::GENERIC_RESERVATION_ERROR) opts = HttpClient::Helper.symbolize_keys(incoming) HttpClient::Preconditions.require_keys(opts, [:messages], 'GenericReservationError') = HttpClient::Preconditions.assert_class('messages', opts.delete(:messages), Array).map { |v| HttpClient::Preconditions.assert_class('messages', v, String) } end |
Instance Attribute Details
#messages ⇒ Object (readonly)
Returns the value of attribute messages.
24347 24348 24349 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 24347 def end |
Instance Method Details
#copy(incoming = {}) ⇒ Object
24360 24361 24362 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 24360 def copy(incoming={}) GenericReservationError.new(subtype_to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end |
#subtype_to_hash ⇒ Object
24364 24365 24366 24367 24368 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 24364 def subtype_to_hash { :messages => } end |
#to_json ⇒ Object
24356 24357 24358 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 24356 def to_json JSON.dump(to_hash) end |