Sha256: 2cc1c56c401dd0d7ad3bbe01271cd3395ccb0d49682d7dd9e09ce6afa5e10a50
Contents?: true
Size: 718 Bytes
Versions: 12
Compression:
Stored size: 718 Bytes
Contents
# encoding: ascii-8bit module Bitcoin module Protocol class Handler def on_inv_transaction(hash) p ['inv transaction', hash.hth] end def on_inv_block(hash) p ['inv block', hash.hth] end def on_get_transaction(hash) p ['get transaction', hash.hth] end def on_get_block(hash) p ['get block', hash.hth] end def on_addr(addr) p ['addr', addr, addr.alive?] end def on_tx(tx) p ['tx', tx] end def on_block(block) #p ['block', block] puts block.to_json end def on_error(message, payload) p ['error', message, payload] end end end end
Version data entries
12 entries across 12 versions & 2 rubygems