class Io::Flow::V0::Models::SurchargeResponsibleParty
Attributes
value[R]
Public Class Methods
ALL()
click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 26948 def SurchargeResponsibleParty.ALL @@all ||= [SurchargeResponsibleParty.organization, SurchargeResponsibleParty.customer] end
apply(value)
click to toggle source
Returns the instance of SurchargeResponsibleParty
for this value, creating a new instance for an unknown value
# File lib/flow_commerce/flow_api_v0_client.rb, line 26933 def SurchargeResponsibleParty.apply(value) if value.instance_of?(SurchargeResponsibleParty) value else HttpClient::Preconditions.assert_class_or_nil('value', value, String) value.nil? ? nil : (from_string(value) || SurchargeResponsibleParty.new(value)) end end
customer()
click to toggle source
The customer pays for this surcharge
# File lib/flow_commerce/flow_api_v0_client.rb, line 26958 def SurchargeResponsibleParty.customer @@_customer ||= SurchargeResponsibleParty.new('customer') end
from_string(value)
click to toggle source
Returns the instance of SurchargeResponsibleParty
for this value, or nil if not found
# File lib/flow_commerce/flow_api_v0_client.rb, line 26943 def SurchargeResponsibleParty.from_string(value) HttpClient::Preconditions.assert_class('value', value, String) SurchargeResponsibleParty.ALL.find { |v| v.value == value } end
new(value)
click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 26928 def initialize(value) @value = HttpClient::Preconditions.assert_class('value', value, String) end
organization()
click to toggle source
The merchant pays for this surcharge
# File lib/flow_commerce/flow_api_v0_client.rb, line 26953 def SurchargeResponsibleParty.organization @@_organization ||= SurchargeResponsibleParty.new('organization') end
Public Instance Methods
to_hash()
click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 26962 def to_hash value end