Class: Ingenico::Connect::SDK::Domain::Refund::RefundResult
- Inherits:
-
Definitions::AbstractOrderStatus
- Object
- Ingenico::Connect::SDK::DataObject
- Definitions::AbstractOrderStatus
- Ingenico::Connect::SDK::Domain::Refund::RefundResult
- Defined in:
- lib/ingenico/connect/sdk/domain/refund/refund_result.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#refund_output ⇒ Ingenico::Connect::SDK::Domain::Payment::RefundOutput
The current value of refund_output.
-
#status ⇒ String
The current value of status.
-
#status_output ⇒ Ingenico::Connect::SDK::Domain::Definitions::OrderStatusOutput
The current value of status_output.
Attributes inherited from Definitions::AbstractOrderStatus
Instance Method Summary collapse
Methods inherited from Ingenico::Connect::SDK::DataObject
Instance Attribute Details
#refund_output ⇒ Ingenico::Connect::SDK::Domain::Payment::RefundOutput
16 17 18 |
# File 'lib/ingenico/connect/sdk/domain/refund/refund_result.rb', line 16 def refund_output @refund_output end |
#status ⇒ String
16 17 18 |
# File 'lib/ingenico/connect/sdk/domain/refund/refund_result.rb', line 16 def status @status end |
#status_output ⇒ Ingenico::Connect::SDK::Domain::Definitions::OrderStatusOutput
16 17 18 |
# File 'lib/ingenico/connect/sdk/domain/refund/refund_result.rb', line 16 def status_output @status_output end |
Instance Method Details
#from_hash(hash) ⇒ Object
33 34 35 36 37 38 39 40 41 42 43 44 45 46 |
# File 'lib/ingenico/connect/sdk/domain/refund/refund_result.rb', line 33 def from_hash(hash) super if hash.has_key? 'refundOutput' raise TypeError, "value '%s' is not a Hash" % [hash['refundOutput']] unless hash['refundOutput'].is_a? Hash @refund_output = Ingenico::Connect::SDK::Domain::Payment::RefundOutput.new_from_hash(hash['refundOutput']) end if hash.has_key? 'status' @status = hash['status'] end if hash.has_key? 'statusOutput' raise TypeError, "value '%s' is not a Hash" % [hash['statusOutput']] unless hash['statusOutput'].is_a? Hash @status_output = Ingenico::Connect::SDK::Domain::Definitions::OrderStatusOutput.new_from_hash(hash['statusOutput']) end end |
#to_h ⇒ Hash
25 26 27 28 29 30 31 |
# File 'lib/ingenico/connect/sdk/domain/refund/refund_result.rb', line 25 def to_h hash = super hash['refundOutput'] = @refund_output.to_h unless @refund_output.nil? hash['status'] = @status unless @status.nil? hash['statusOutput'] = @status_output.to_h unless @status_output.nil? hash end |