Documentation ¶
Index ¶
- Constants
- Variables
- func AddRelayer(client *Client, bridge, relayer common.Address) error
- func ConstructErc20DepositData(destRecipient []byte, amount *big.Int) []byte
- func CreateErc20Deposit(client *Client, bridge common.Address, destId msg.ChainId, recipient []byte, ...) error
- func Erc20AddMinter(client *Client, erc20Contract, handler common.Address) error
- func Erc20Approve(client *Client, erc20Contract, recipient common.Address, amount *big.Int) error
- func Erc20GetAllowance(client *Client, erc20Contract, owner, spender common.Address) (*big.Int, error)
- func Erc20GetBalance(client *Client, erc20Contract, account common.Address) (*big.Int, error)
- func Erc20GetResourceId(client *Client, handler common.Address, rId msg.ResourceId) (common.Address, error)
- func GetDepositNonce(client *Client, bridge common.Address, chain msg.ChainId) (uint64, error)
- func Hash(data []byte) [32]byte
- func IDAndNonce(srcId msg.ChainId, nonce msg.Nonce) *big.Int
- func SetResourceAndBurnable(client *Client, bridge, handler common.Address, rIds [][32]byte, ...) error
- func UpdateNonce(client *Client) error
- func WaitForTx(client *Client, tx *ethtypes.Transaction) error
- type Client
- type DeployedContracts
- type EventSig
- type ProposalStatus
Constants ¶
View Source
const DefaultGasLimit = 6721975
View Source
const DefaultMaxGasPrice = 20000000000
Variables ¶
View Source
var ( RelayerAddresses = []common.Address{ common.HexToAddress(keystore.TestKeyRing.EthereumKeys[keystore.AliceKey].Address()), common.HexToAddress(keystore.TestKeyRing.EthereumKeys[keystore.BobKey].Address()), common.HexToAddress(keystore.TestKeyRing.EthereumKeys[keystore.CharlieKey].Address()), common.HexToAddress(keystore.TestKeyRing.EthereumKeys[keystore.DaveKey].Address()), common.HexToAddress(keystore.TestKeyRing.EthereumKeys[keystore.EveKey].Address()), } ZeroAddress = common.HexToAddress("0x0000000000000000000000000000000000000000") )
View Source
var ExpectedBlockTime = time.Second
Functions ¶
func CreateErc20Deposit ¶
func Erc20AddMinter ¶
func Erc20Approve ¶
func Erc20GetAllowance ¶
func Erc20GetBalance ¶
func Erc20GetResourceId ¶
func GetDepositNonce ¶
func SetResourceAndBurnable ¶
func UpdateNonce ¶
Types ¶
type Client ¶
type Client struct { Client *ethclient.Client Opts *bind.TransactOpts CallOpts *bind.CallOpts // contains filtered or unexported fields }
func (*Client) LockNonceAndUpdate ¶
func (*Client) UnlockNonce ¶
func (c *Client) UnlockNonce()
type DeployedContracts ¶
type ProposalStatus ¶
type ProposalStatus int
const ( Inactive ProposalStatus = iota Active Executed Cancelled )
Click to show internal directories.
Click to hide internal directories.