blockchain

package
v0.0.0-...-12b389a Latest Latest
Warning

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

Go to latest
Published: Apr 7, 2022 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client to manage connection to Ethereum

func (*Client) AccountPermitted

func (ec *Client) AccountPermitted(contractAddress, senderAddress common.Address) (bool, error)

AccountPermitted ...

func (*Client) Close

func (ec *Client) Close()

Close ethereum connection

func (*Client) ConfigTransaction

func (ec *Client) ConfigTransaction(key *ecdsa.PrivateKey, gasLimit uint64, pending bool) (*bind.TransactOpts, error)

ConfigTransaction from ethereum address contract

func (*Client) Connect

func (ec *Client) Connect(nodeURL string) error

Connect to Ethereum

func (*Client) DecreaseGasUsed

func (ec *Client) DecreaseGasUsed(contractAddress common.Address, options *bind.TransactOpts, gasUsed *big.Int) (*common.Hash, error)

DecreaseGasUsed into blockchain

func (*Client) GenerateTransaction

func (ec *Client) GenerateTransaction(options *bind.TransactOpts, to *common.Address, relayAddress common.Address, signingData []byte, v uint8, r, s [32]byte) (*types.Transaction, error)

func (*Client) GetBlockByNumber

func (ec *Client) GetBlockByNumber(contractAddress common.Address, blockNumber *big.Int) (*types.Header, uint64, error)

GetBlockByNumber ...

func (*Client) GetCurrentGasLimit

func (ec *Client) GetCurrentGasLimit(contractAddress common.Address) (*big.Int, error)

GetMaxBlockGasLimit ...

func (*Client) GetEthclient

func (ec *Client) GetEthclient() *ethclient.Client

GetEthclient ...

func (*Client) GetGasLimit

func (ec *Client) GetGasLimit(contractAddress, nodeAddress common.Address) (*big.Int, error)

GetGasLimit ...

func (*Client) GetMaxBlockGasLimit

func (ec *Client) GetMaxBlockGasLimit(contractAddress common.Address) (*big.Int, error)

GetMaxBlockGasLimit ...

func (*Client) GetTransactionCount

func (ec *Client) GetTransactionCount(contractAddress common.Address, address common.Address, nodeAddress common.Address) (*big.Int, error)

GetTransactionCount ...

func (*Client) GetTransactionReceipt

func (ec *Client) GetTransactionReceipt(transactionHash common.Hash) (*types.Receipt, error)

GetTransactionReceipt ...

func (*Client) SendMetatransaction

func (ec *Client) SendMetatransaction(contractAddress common.Address, options *bind.TransactOpts, to *common.Address, signingData []byte, v uint8, r [32]byte, s [32]byte) (*common.Hash, error)

SendMetatransaction into blockchain

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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