Class: Io::Flow::V0::Models::Issuer
- Inherits:
-
Object
- Object
- Io::Flow::V0::Models::Issuer
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Instance Attribute Summary collapse
-
#card_brand ⇒ Object
readonly
Returns the value of attribute card_brand.
-
#card_type ⇒ Object
readonly
Returns the value of attribute card_type.
-
#iin ⇒ Object
readonly
Returns the value of attribute iin.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
Instance Method Summary collapse
- #copy(incoming = {}) ⇒ Object
-
#initialize(incoming = {}) ⇒ Issuer
constructor
A new instance of Issuer.
- #to_hash ⇒ Object
- #to_json ⇒ Object
Constructor Details
#initialize(incoming = {}) ⇒ Issuer
Returns a new instance of Issuer.
26161 26162 26163 26164 26165 26166 26167 26168 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 26161 def initialize(incoming={}) opts = HttpClient::Helper.symbolize_keys(incoming) HttpClient::Preconditions.require_keys(opts, [:iin, :card_brand], 'Issuer') @iin = HttpClient::Preconditions.assert_class('iin', opts.delete(:iin), String) @card_brand = HttpClient::Preconditions.assert_class('card_brand', opts.delete(:card_brand), String) @card_type = (x = opts.delete(:card_type); x.nil? ? nil : HttpClient::Preconditions.assert_class('card_type', x, String)) @name = (x = opts.delete(:name); x.nil? ? nil : HttpClient::Preconditions.assert_class('name', x, String)) end |
Instance Attribute Details
#card_brand ⇒ Object (readonly)
Returns the value of attribute card_brand.
26159 26160 26161 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 26159 def card_brand @card_brand end |
#card_type ⇒ Object (readonly)
Returns the value of attribute card_type.
26159 26160 26161 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 26159 def card_type @card_type end |
#iin ⇒ Object (readonly)
Returns the value of attribute iin.
26159 26160 26161 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 26159 def iin @iin end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
26159 26160 26161 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 26159 def name @name end |
Instance Method Details
#copy(incoming = {}) ⇒ Object
26174 26175 26176 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 26174 def copy(incoming={}) Issuer.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end |
#to_hash ⇒ Object
26178 26179 26180 26181 26182 26183 26184 26185 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 26178 def to_hash { :iin => iin, :card_brand => card_brand, :card_type => card_type, :name => name } end |
#to_json ⇒ Object
26170 26171 26172 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 26170 def to_json JSON.dump(to_hash) end |