Documentation ¶
Index ¶
- Constants
- func ApproveErc20Transfer(erc20, gravityContract string, privKey *ecdsa.PrivateKey, ...) (*web3.Hash, error)
- func CheckErc20Approved(erc20, ownAddress, targetContract string, client *jsonrpc.Client) (bool, error)
- func CheckForEvents(startBlock, endBlock uint64, contractAddr []string, events []string, ...) ([]*web3.Log, error)
- func DeployErc20(cosmosDenom, erc20Name, erc20Symbol string, decimals uint8, ...) (*web3.Hash, error)
- func GetEventNonce(contractAddr string, ourEthereumAddress common.Address, client *jsonrpc.Client) (uint64, error)
- func GetGravityId(contractAddr string, ourEthereumAddress common.Address, client *jsonrpc.Client) ([]byte, error)
- func GetTxBatchNonce(contractAddr string, erc20Addr, ourEthereumAddress common.Address, ...) (uint64, error)
- func GetValSetNonce(contractAddr string, ourEthereumAddress common.Address, client *jsonrpc.Client) (uint64, error)
- func SendEthTransactionBatch(currentValset types.ValSet, batch types.TransactionBatch, ...) error
- func SendEthValsetUpdate(newValset, oldValset types.ValSet, confirms []types.ValsetConfirmResponse, ...) error
- func SendToCosmos(erc20, gravityContract string, amount *big.Int, ...) (*web3.Hash, error)
- func SendTransaction(client *jsonrpc.Client, toAddress string, data []byte, value *big.Int, ...) (*web3.Hash, error)
- func WaitForEvent(timeout time.Duration, contractAddress, event string, topics []*web3.Hash, ...) ([]*web3.Log, error)
- func WaitForTransaction(client *jsonrpc.Client, hash *web3.Hash, timeout time.Duration, ...) (*web3.Transaction, error)
- type GasCost
Constants ¶
View Source
const (
GasLimit uint64 = 7000000
)
Variables ¶
This section is empty.
Functions ¶
func ApproveErc20Transfer ¶
func CheckErc20Approved ¶
func CheckForEvents ¶
func DeployErc20 ¶
func GetEventNonce ¶
func GetGravityId ¶
func GetTxBatchNonce ¶
func GetValSetNonce ¶
func SendEthTransactionBatch ¶
func SendEthTransactionBatch( currentValset types.ValSet, batch types.TransactionBatch, confirms []types.BatchConfirmResponse, client *jsonrpc.Client, timeout time.Duration, gravityContractAddr string, gravityId string, EthKey *ecdsa.PrivateKey, ) error
func SendEthValsetUpdate ¶
func SendToCosmos ¶
func SendTransaction ¶
func WaitForEvent ¶
Types ¶
type GasCost ¶
func EstimateValsetCost ¶
Click to show internal directories.
Click to hide internal directories.