Class: Io::Flow::V0::Models::IdentifierForm
- Inherits:
-
Object
- Object
- Io::Flow::V0::Models::IdentifierForm
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Instance Attribute Summary collapse
-
#primary ⇒ Object
readonly
Returns the value of attribute primary.
Instance Method Summary collapse
- #copy(incoming = {}) ⇒ Object
-
#initialize(incoming = {}) ⇒ IdentifierForm
constructor
A new instance of IdentifierForm.
- #to_hash ⇒ Object
- #to_json ⇒ Object
Constructor Details
#initialize(incoming = {}) ⇒ IdentifierForm
Returns a new instance of IdentifierForm.
25057 25058 25059 25060 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 25057 def initialize(incoming={}) opts = HttpClient::Helper.symbolize_keys(incoming) @primary = (x = opts.delete(:primary); x.nil? ? nil : HttpClient::Preconditions.assert_boolean('primary', x)) end |
Instance Attribute Details
#primary ⇒ Object (readonly)
Returns the value of attribute primary.
25055 25056 25057 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 25055 def primary @primary end |
Instance Method Details
#copy(incoming = {}) ⇒ Object
25066 25067 25068 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 25066 def copy(incoming={}) IdentifierForm.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end |
#to_hash ⇒ Object
25070 25071 25072 25073 25074 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 25070 def to_hash { :primary => primary } end |
#to_json ⇒ Object
25062 25063 25064 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 25062 def to_json JSON.dump(to_hash) end |