Class: Wallet
- Inherits:
-
Object
- Object
- Wallet
- Defined in:
- lib/shilling/wallet.rb
Overview
Single Address Wallet
Instance Attribute Summary collapse
-
#address ⇒ Object
readonly
Returns the value of attribute address.
Instance Method Summary collapse
- #generate_transaction(to, amount) ⇒ Object
-
#initialize(address) ⇒ Wallet
constructor
A new instance of Wallet.
Constructor Details
#initialize(address) ⇒ Wallet
Returns a new instance of Wallet.
7 8 9 |
# File 'lib/shilling/wallet.rb', line 7 def initialize( address ) @address = address end |
Instance Attribute Details
#address ⇒ Object (readonly)
Returns the value of attribute address.
5 6 7 |
# File 'lib/shilling/wallet.rb', line 5 def address @address end |
Instance Method Details
#generate_transaction(to, amount) ⇒ Object
11 12 13 |
# File 'lib/shilling/wallet.rb', line 11 def generate_transaction( to, amount ) Tx.new( address, to, amount ) end |