Class: Io::Flow::V0::Models::EmailPaymentSummary
- Inherits:
-
Object
- Object
- Io::Flow::V0::Models::EmailPaymentSummary
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Instance Attribute Summary collapse
-
#refund ⇒ Object
readonly
Returns the value of attribute refund.
Instance Method Summary collapse
- #copy(incoming = {}) ⇒ Object
-
#initialize(incoming = {}) ⇒ EmailPaymentSummary
constructor
A new instance of EmailPaymentSummary.
- #to_hash ⇒ Object
- #to_json ⇒ Object
Constructor Details
#initialize(incoming = {}) ⇒ EmailPaymentSummary
Returns a new instance of EmailPaymentSummary.
35967 35968 35969 35970 35971 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 35967 def initialize(incoming={}) opts = HttpClient::Helper.symbolize_keys(incoming) HttpClient::Preconditions.require_keys(opts, [:refund], 'EmailPaymentSummary') @refund = (x = opts.delete(:refund); x.is_a?(::Io::Flow::V0::Models::Refund) ? x : ::Io::Flow::V0::Models::Refund.new(x)) end |
Instance Attribute Details
#refund ⇒ Object (readonly)
Returns the value of attribute refund.
35965 35966 35967 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 35965 def refund @refund end |
Instance Method Details
#copy(incoming = {}) ⇒ Object
35977 35978 35979 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 35977 def copy(incoming={}) EmailPaymentSummary.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end |
#to_hash ⇒ Object
35981 35982 35983 35984 35985 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 35981 def to_hash { :refund => refund.to_hash } end |
#to_json ⇒ Object
35973 35974 35975 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 35973 def to_json JSON.dump(to_hash) end |