Class: Io::Flow::V0::Models::OrganizationTokenFormV2
- Inherits:
-
Object
- Object
- Io::Flow::V0::Models::OrganizationTokenFormV2
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Instance Attribute Summary collapse
-
#description ⇒ Object
readonly
Returns the value of attribute description.
-
#organization_id ⇒ Object
readonly
Returns the value of attribute organization_id.
Instance Method Summary collapse
- #copy(incoming = {}) ⇒ Object
-
#initialize(incoming = {}) ⇒ OrganizationTokenFormV2
constructor
A new instance of OrganizationTokenFormV2.
- #to_hash ⇒ Object
- #to_json ⇒ Object
Constructor Details
#initialize(incoming = {}) ⇒ OrganizationTokenFormV2
Returns a new instance of OrganizationTokenFormV2.
51422 51423 51424 51425 51426 51427 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 51422 def initialize(incoming={}) opts = HttpClient::Helper.symbolize_keys(incoming) HttpClient::Preconditions.require_keys(opts, [:organization_id], 'OrganizationTokenFormV2') @organization_id = HttpClient::Preconditions.assert_class('organization_id', opts.delete(:organization_id), String) @description = (x = opts.delete(:description); x.nil? ? nil : HttpClient::Preconditions.assert_class('description', x, String)) end |
Instance Attribute Details
#description ⇒ Object (readonly)
Returns the value of attribute description.
51420 51421 51422 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 51420 def description @description end |
#organization_id ⇒ Object (readonly)
Returns the value of attribute organization_id.
51420 51421 51422 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 51420 def organization_id @organization_id end |
Instance Method Details
#copy(incoming = {}) ⇒ Object
51433 51434 51435 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 51433 def copy(incoming={}) OrganizationTokenFormV2.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end |
#to_hash ⇒ Object
51437 51438 51439 51440 51441 51442 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 51437 def to_hash { :organization_id => organization_id, :description => description } end |
#to_json ⇒ Object
51429 51430 51431 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 51429 def to_json JSON.dump(to_hash) end |