Class: Ingenico::Direct::SDK::Domain::PayoutResult
- Inherits:
-
Ingenico::Direct::SDK::DataObject
- Object
- Ingenico::Direct::SDK::DataObject
- Ingenico::Direct::SDK::Domain::PayoutResult
- Defined in:
- lib/ingenico/direct/sdk/domain/payout_result.rb
Instance Attribute Summary collapse
-
#id ⇒ String
The current value of id.
-
#payout_output ⇒ Ingenico::Direct::SDK::Domain::PayoutOutput
The current value of payout_output.
-
#status ⇒ String
The current value of status.
-
#status_output ⇒ Ingenico::Direct::SDK::Domain::PayoutStatusOutput
The current value of status_output.
Instance Method Summary collapse
Methods inherited from Ingenico::Direct::SDK::DataObject
Instance Attribute Details
#id ⇒ String
Returns the current value of id.
16 17 18 |
# File 'lib/ingenico/direct/sdk/domain/payout_result.rb', line 16 def id @id end |
#payout_output ⇒ Ingenico::Direct::SDK::Domain::PayoutOutput
Returns the current value of payout_output.
16 17 18 |
# File 'lib/ingenico/direct/sdk/domain/payout_result.rb', line 16 def payout_output @payout_output end |
#status ⇒ String
Returns the current value of status.
16 17 18 |
# File 'lib/ingenico/direct/sdk/domain/payout_result.rb', line 16 def status @status end |
#status_output ⇒ Ingenico::Direct::SDK::Domain::PayoutStatusOutput
Returns the current value of status_output.
16 17 18 |
# File 'lib/ingenico/direct/sdk/domain/payout_result.rb', line 16 def status_output @status_output end |
Instance Method Details
#from_hash(hash) ⇒ Object
32 33 34 35 36 37 38 39 40 41 42 43 44 |
# File 'lib/ingenico/direct/sdk/domain/payout_result.rb', line 32 def from_hash(hash) super @id = hash['id'] if hash.key? 'id' if hash.key? 'payoutOutput' raise TypeError, "value '%s' is not a Hash" % [hash['payoutOutput']] unless hash['payoutOutput'].is_a? Hash @payout_output = Ingenico::Direct::SDK::Domain::PayoutOutput.new_from_hash(hash['payoutOutput']) end @status = hash['status'] if hash.key? 'status' if hash.key? 'statusOutput' raise TypeError, "value '%s' is not a Hash" % [hash['statusOutput']] unless hash['statusOutput'].is_a? Hash @status_output = Ingenico::Direct::SDK::Domain::PayoutStatusOutput.new_from_hash(hash['statusOutput']) end end |
#to_h ⇒ Hash
23 24 25 26 27 28 29 30 |
# File 'lib/ingenico/direct/sdk/domain/payout_result.rb', line 23 def to_h hash = super hash['id'] = @id unless @id.nil? hash['payoutOutput'] = @payout_output.to_h if @payout_output hash['status'] = @status unless @status.nil? hash['statusOutput'] = @status_output.to_h if @status_output hash end |