Class: NanoRpc::Wallet

Inherits:
Object
  • Object
show all
Includes:
Proxy, WalletHelper
Defined in:
lib/nano_rpc/proxies/wallet.rb

Instance Attribute Summary collapse

Attributes included from Proxy

#node

Instance Method Summary collapse

Methods included from WalletHelper

#account_work, #account_work_set, #accounts, #add_key, #add_watch, #balance, #balances, #begin_payment, #change_password, #change_seed, #contains?, #create_account, #create_accounts, #destroy, #enter_password, #export, #frontiers, #init_payment, #ledger, #locked?, #move_accounts, #password_valid?, #pending_balance, #pending_balances, #pending_blocks, #receive_block, #remove_account, #representative, #representative_set, #republish, #send_nano, #work

Methods included from Proxy

included, #proxy_methods

Constructor Details

#initialize(id = nil, opts = {}) ⇒ Wallet

Returns a new instance of Wallet.



8
9
10
11
12
13
14
15
16
# File 'lib/nano_rpc/proxies/wallet.rb', line 8

def initialize(id = nil, opts = {})
  unless id.is_a?(String)
    raise NanoRpc::MissingParameters,
          'Missing argument: id (str)'
  end

  @id = id
  super(opts)
end

Instance Attribute Details

#idObject (readonly)

Returns the value of attribute id.



6
7
8
# File 'lib/nano_rpc/proxies/wallet.rb', line 6

def id
  @id
end