Class: SixSaferpay::CaptureReference
- Inherits:
-
Object
- Object
- SixSaferpay::CaptureReference
- Defined in:
- lib/six_saferpay/models/capture_reference.rb
Instance Attribute Summary collapse
-
#capture_id ⇒ Object
Returns the value of attribute capture_id.
-
#order_id ⇒ Object
Returns the value of attribute order_id.
-
#order_part_id ⇒ Object
Returns the value of attribute order_part_id.
-
#transaction_id ⇒ Object
Returns the value of attribute transaction_id.
Instance Method Summary collapse
-
#initialize(capture_id: nil, transaction_id: nil, order_id: nil, order_part_id: nil) ⇒ CaptureReference
constructor
A new instance of CaptureReference.
- #to_hash ⇒ Object (also: #to_h)
Constructor Details
#initialize(capture_id: nil, transaction_id: nil, order_id: nil, order_part_id: nil) ⇒ CaptureReference
Returns a new instance of CaptureReference.
10 11 12 13 14 15 16 17 18 19 20 |
# File 'lib/six_saferpay/models/capture_reference.rb', line 10 def initialize(capture_id: nil, transaction_id: nil, order_id: nil, order_part_id: nil ) @capture_id = capture_id @transaction_id = transaction_id @order_id = order_id @order_part_id = order_part_id end |
Instance Attribute Details
#capture_id ⇒ Object
Returns the value of attribute capture_id.
4 5 6 |
# File 'lib/six_saferpay/models/capture_reference.rb', line 4 def capture_id @capture_id end |
#order_id ⇒ Object
Returns the value of attribute order_id.
4 5 6 |
# File 'lib/six_saferpay/models/capture_reference.rb', line 4 def order_id @order_id end |
#order_part_id ⇒ Object
Returns the value of attribute order_part_id.
4 5 6 |
# File 'lib/six_saferpay/models/capture_reference.rb', line 4 def order_part_id @order_part_id end |
#transaction_id ⇒ Object
Returns the value of attribute transaction_id.
4 5 6 |
# File 'lib/six_saferpay/models/capture_reference.rb', line 4 def transaction_id @transaction_id end |
Instance Method Details
#to_hash ⇒ Object Also known as: to_h
22 23 24 25 26 27 28 29 |
# File 'lib/six_saferpay/models/capture_reference.rb', line 22 def to_hash hash = Hash.new hash.merge!(capture_id: @capture_id) if @capture_id hash.merge!(transaction_id: @transaction_id) if @transaction_id hash.merge!(order_id: @order_id) if @order_id hash.merge!(order_part_id: @order_part_id) if @order_part_id hash end |