Class: Cryptoprocessing::Address

Inherits:
APIObject
  • Object
show all
Defined in:
lib/cryptoprocessing/models/address.rb

Instance Method Summary collapse

Methods inherited from APIObject

#initialize, #update

Constructor Details

This class inherits a constructor from Cryptoprocessing::APIObject

Instance Method Details

#create_transaction(to_address, amount, options = {}) ⇒ Object



11
12
13
14
15
# File 'lib/cryptoprocessing/models/address.rb', line 11

def create_transaction(to_address, amount, options = {})
  agent.create_transaction(self['account_id'], self['address'], to_address, amount, options) do |data, resp|
    yield(data, resp) if block_given?
  end
end

#transactions(options = {}) ⇒ Object



5
6
7
8
9
# File 'lib/cryptoprocessing/models/address.rb', line 5

def transactions(options = {})
  agent.transactions_by_address(self['account_id'], self['address'], options) do |data, resp|
    yield(data, resp) if block_given?
  end
end