Class: Io::Flow::V0::Models::OrderMerchantOfRecord
- Inherits:
-
Object
- Object
- Io::Flow::V0::Models::OrderMerchantOfRecord
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Instance Attribute Summary collapse
-
#value ⇒ Object
readonly
Returns the value of attribute value.
Class Method Summary collapse
- .ALL ⇒ Object
-
.apply(value) ⇒ Object
Returns the instance of OrderMerchantOfRecord for this value, creating a new instance for an unknown value.
- .flow ⇒ Object
-
.from_string(value) ⇒ Object
Returns the instance of OrderMerchantOfRecord for this value, or nil if not found.
- .mixed ⇒ Object
- .organization ⇒ Object
Instance Method Summary collapse
-
#initialize(value) ⇒ OrderMerchantOfRecord
constructor
A new instance of OrderMerchantOfRecord.
- #to_hash ⇒ Object
Constructor Details
#initialize(value) ⇒ OrderMerchantOfRecord
Returns a new instance of OrderMerchantOfRecord.
17355 17356 17357 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 17355 def initialize(value) @value = HttpClient::Preconditions.assert_class('value', value, String) end |
Instance Attribute Details
#value ⇒ Object (readonly)
Returns the value of attribute value.
17353 17354 17355 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 17353 def value @value end |
Class Method Details
.ALL ⇒ Object
17375 17376 17377 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 17375 def OrderMerchantOfRecord.ALL @@all ||= [OrderMerchantOfRecord.flow, OrderMerchantOfRecord.organization, OrderMerchantOfRecord.mixed] end |
.apply(value) ⇒ Object
Returns the instance of OrderMerchantOfRecord for this value, creating a new instance for an unknown value
17360 17361 17362 17363 17364 17365 17366 17367 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 17360 def OrderMerchantOfRecord.apply(value) if value.instance_of?(OrderMerchantOfRecord) value else HttpClient::Preconditions.assert_class_or_nil('value', value, String) value.nil? ? nil : (from_string(value) || OrderMerchantOfRecord.new(value)) end end |
.flow ⇒ Object
17379 17380 17381 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 17379 def OrderMerchantOfRecord.flow @@_flow ||= OrderMerchantOfRecord.new('flow') end |
.from_string(value) ⇒ Object
Returns the instance of OrderMerchantOfRecord for this value, or nil if not found
17370 17371 17372 17373 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 17370 def OrderMerchantOfRecord.from_string(value) HttpClient::Preconditions.assert_class('value', value, String) OrderMerchantOfRecord.ALL.find { |v| v.value == value } end |
.mixed ⇒ Object
17387 17388 17389 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 17387 def OrderMerchantOfRecord.mixed @@_mixed ||= OrderMerchantOfRecord.new('mixed') end |
.organization ⇒ Object
17383 17384 17385 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 17383 def OrderMerchantOfRecord.organization @@_organization ||= OrderMerchantOfRecord.new('organization') end |
Instance Method Details
#to_hash ⇒ Object
17391 17392 17393 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 17391 def to_hash value end |