Class: NetRegistry::Transaction

Inherits:
Object
  • Object
show all
Defined in:
lib/net_registry/transaction.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#amountObject

Returns the value of attribute amount.



27
28
29
# File 'lib/net_registry/transaction.rb', line 27

def amount
  @amount
end

#bank_referenceObject

Returns the value of attribute bank_reference.



27
28
29
# File 'lib/net_registry/transaction.rb', line 27

def bank_reference
  @bank_reference
end

#commandObject

Returns the value of attribute command.



27
28
29
# File 'lib/net_registry/transaction.rb', line 27

def command
  @command
end

#merchant_idObject

Returns the value of attribute merchant_id.



27
28
29
# File 'lib/net_registry/transaction.rb', line 27

def merchant_id
  @merchant_id
end

#numberObject

Returns the value of attribute number.



27
28
29
# File 'lib/net_registry/transaction.rb', line 27

def number
  @number
end

#receiptObject

Returns the value of attribute receipt.



27
28
29
# File 'lib/net_registry/transaction.rb', line 27

def receipt
  @receipt
end

#referenceObject

Returns the value of attribute reference.



27
28
29
# File 'lib/net_registry/transaction.rb', line 27

def reference
  @reference
end

#rrnObject

Returns the value of attribute rrn.



27
28
29
# File 'lib/net_registry/transaction.rb', line 27

def rrn
  @rrn
end

#settlement_dateObject

Returns the value of attribute settlement_date.



27
28
29
# File 'lib/net_registry/transaction.rb', line 27

def settlement_date
  @settlement_date
end

#timeObject

Returns the value of attribute time.



27
28
29
# File 'lib/net_registry/transaction.rb', line 27

def time
  @time
end

Instance Method Details

#cardObject



43
44
45
# File 'lib/net_registry/transaction.rb', line 43

def card
  @card ||= NetRegistry::Card.new
end

#card=(card) ⇒ Object

Raises:

  • (TypeError)


38
39
40
41
# File 'lib/net_registry/transaction.rb', line 38

def card=(card)
  raise TypeError, "Invalid class" if !card.is_a? NetRegistry::Card
  @card = card
end