Class: Io::Flow::V0::Models::PaymentProcessorIdentifier
- Inherits:
-
Object
- Object
- Io::Flow::V0::Models::PaymentProcessorIdentifier
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Instance Attribute Summary collapse
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#label ⇒ Object
readonly
Returns the value of attribute label.
Instance Method Summary collapse
- #copy(incoming = {}) ⇒ Object
-
#initialize(incoming = {}) ⇒ PaymentProcessorIdentifier
constructor
A new instance of PaymentProcessorIdentifier.
- #to_hash ⇒ Object
- #to_json ⇒ Object
Constructor Details
#initialize(incoming = {}) ⇒ PaymentProcessorIdentifier
Returns a new instance of PaymentProcessorIdentifier.
54035 54036 54037 54038 54039 54040 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 54035 def initialize(incoming={}) opts = HttpClient::Helper.symbolize_keys(incoming) HttpClient::Preconditions.require_keys(opts, [:id, :label], 'PaymentProcessorIdentifier') @id = HttpClient::Preconditions.assert_class('id', opts.delete(:id), String) @label = HttpClient::Preconditions.assert_class('label', opts.delete(:label), String) end |
Instance Attribute Details
#id ⇒ Object (readonly)
Returns the value of attribute id.
54033 54034 54035 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 54033 def id @id end |
#label ⇒ Object (readonly)
Returns the value of attribute label.
54033 54034 54035 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 54033 def label @label end |
Instance Method Details
#copy(incoming = {}) ⇒ Object
54046 54047 54048 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 54046 def copy(incoming={}) PaymentProcessorIdentifier.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end |
#to_hash ⇒ Object
54050 54051 54052 54053 54054 54055 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 54050 def to_hash { :id => id, :label => label } end |
#to_json ⇒ Object
54042 54043 54044 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 54042 def to_json JSON.dump(to_hash) end |