btg

package
v0.3.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 5, 2020 License: AGPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// MainnetMagic is mainnet network constant
	MainnetMagic wire.BitcoinNet = 0x446d47e1
	// TestnetMagic is testnet network constant
	TestnetMagic wire.BitcoinNet = 0x456e48e2
)

Variables

View Source
var (
	// MainNetParams are parser parameters for mainnet
	MainNetParams chaincfg.Params
	// TestNetParams are parser parameters for testnet
	TestNetParams chaincfg.Params
)

Functions

func GetChainParams

func GetChainParams(chain string) *chaincfg.Params

GetChainParams contains network parameters for the main Bitcoin Cash network, the regression test Bitcoin Cash network, the test Bitcoin Cash network and the simulation test Bitcoin Cash network, in this order

func NewBGoldRPC

func NewBGoldRPC(config json.RawMessage, pushHandler func(bchain.NotificationType)) (bchain.BlockChain, error)

NewBGoldRPC returns new BGoldRPC instance.

Types

type BGoldParser

type BGoldParser struct {
	*btc.BitcoinParser
}

BGoldParser handle

func NewBGoldParser

func NewBGoldParser(params *chaincfg.Params, c *btc.Configuration) *BGoldParser

NewBGoldParser returns new BGoldParser instance

func (*BGoldParser) ParseBlock

func (p *BGoldParser) ParseBlock(b []byte) (*bchain.Block, error)

ParseBlock parses raw block to our Block struct

type BGoldRPC

type BGoldRPC struct {
	*btc.BitcoinRPC
}

BGoldRPC is an interface to JSON-RPC bitcoind service.

func (*BGoldRPC) Initialize

func (b *BGoldRPC) Initialize() error

Initialize initializes BGoldRPC instance.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL