class SixSaferpay::CaptureReference

Attributes

capture_id[RW]
order_id[RW]
order_part_id[RW]
transaction_id[RW]

Public Class Methods

new(capture_id: nil, transaction_id: nil, order_id: nil, order_part_id: nil ) click to toggle source
# 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

Public Instance Methods

to_h()
Alias for: to_hash
to_hash() click to toggle source
# 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
Also aliased as: to_h