ethclient

package
v0.0.0-...-a5eb945 Latest Latest
Warning

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

Go to latest
Published: Oct 10, 2018 License: GPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Conn

type Conn struct {
	// contains filtered or unexported fields
}

func Connect

func Connect(config network.Config) (Conn, error)

Connect to an ethereum network.

func (*Conn) Client

func (conn *Conn) Client() *ethclient.Client

func (*Conn) Network

func (conn *Conn) Network() string

func (*Conn) NewAccount

func (b *Conn) NewAccount(value int64, from *bind.TransactOpts) (common.Address, *bind.TransactOpts, error)

NewAccount creates a new account and funds it with ether

func (*Conn) OrderbookAddress

func (conn *Conn) OrderbookAddress() common.Address

func (*Conn) PatchedWaitDeployed

func (b *Conn) PatchedWaitDeployed(ctx context.Context, tx *types.Transaction) (common.Address, error)

PatchedWaitDeployed waits for a contract deployment transaction and returns the on-chain contract address when it is mined. It stops waiting when ctx is canceled.

TODO: THIS DOES NOT WORK WITH PARITY, WHICH SENDS A TRANSACTION RECEIPT UPON RECEIVING A TX, NOT AFTER IT'S MINED

func (*Conn) PatchedWaitMined

func (b *Conn) PatchedWaitMined(ctx context.Context, tx *types.Transaction) (*types.Receipt, error)

PatchedWaitMined waits for tx to be mined on the blockchain. It stops waiting when the context is canceled.

TODO: THIS DOES NOT WORK WITH PARITY, WHICH SENDS A TRANSACTION RECEIPT UPON RECEIVING A TX, NOT AFTER IT'S MINED

func (*Conn) RenExAtomicInfoAddress

func (conn *Conn) RenExAtomicInfoAddress() common.Address

func (*Conn) RenExAtomicSwapperAddress

func (conn *Conn) RenExAtomicSwapperAddress() common.Address

func (*Conn) RenExSettlementAddress

func (conn *Conn) RenExSettlementAddress() common.Address

func (*Conn) Transfer

func (b *Conn) Transfer(to common.Address, from *bind.TransactOpts, value int64) error

Transfer is a helper function for sending ETH to an address

Jump to

Keyboard shortcuts

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