Documentation
¶
Index ¶
- Constants
- func ChainID(network Network) uint64
- func ERC1155InterfaceID() [4]byte
- func ERC20AllowanceMethod() common.Hash
- func ERC20ApprovalEvent() common.Hash
- func ERC20ApproveMethod() common.Hash
- func ERC20BalanceOfMethod() common.Hash
- func ERC20MustEventIDs() map[string]struct{}
- func ERC20MustMethodIDs() map[string]struct{}
- func ERC20TotalSupplyMethod() common.Hash
- func ERC20TransderFromMethod() common.Hash
- func ERC20TransferEvent() common.Hash
- func ERC20TransferMethod() common.Hash
- func ERC721InterfaceID() [4]byte
- func ERC721MetadataInterfaceID() [4]byte
- func ERC721MustEventIDs() map[string]struct{}
- func ERC721MustMethodIDs() map[string]struct{}
- func EthereumAddress() common.Address
- func NetworkStrings() []string
- func Opposite(number *big.Int) *big.Int
- func USDContractAddress(network Network) common.Address
- func USDDecimals(network Network) uint8
- func UniswapPostitionTransferEvent() common.Hash
- func ZeroAddress() common.Address
- func ZeroBigInt() *big.Int
- type Network
Constants ¶
View Source
const ( IndexerCommandName = "indexer" RelayerCommandName = "relayer" )
View Source
const ( SNXDecimals = 18 SNXSymbol = "SNX" )
View Source
const ( SUSDDecimals = 18 SUSDSymbol = "sUSD" )
View Source
const ( USDTDecimalsInEthereum = 6 USDTDecimalsInArbitrum = 6 USDTDecimalsInOptimism = 6 USDTDecimalsInPolygon = 6 BUSDDecimalsInBSC = 18 )
View Source
const ( USDTAddressInEthereum = "0xdAC17F958D2ee523a2206206994597C13D831ec7" USDTAddressInPolygon = "0xc2132D05D31c914a87C6611C10748AEb04B58e8F" USDTAddressInArbitrum = "0xFd086bC7CD5C481DCC9C85ebE478A1C0b69FCbb9" USDTAddressInOptimism = "0x94b008aa00579c1307b0ef2c499ad98a8ce58e58" BUSDAddressInBSC = "0xe9e7CEA3DedcA5984780Bafc599bD69ADd087D56" )
View Source
const (
EthereumDecimals = 18
)
Variables ¶
This section is empty.
Functions ¶
func ERC1155InterfaceID ¶
func ERC1155InterfaceID() [4]byte
func ERC20AllowanceMethod ¶
func ERC20ApprovalEvent ¶
func ERC20ApproveMethod ¶
func ERC20BalanceOfMethod ¶
func ERC20MustEventIDs ¶
func ERC20MustEventIDs() map[string]struct{}
func ERC20MustMethodIDs ¶
func ERC20MustMethodIDs() map[string]struct{}
func ERC20TotalSupplyMethod ¶
func ERC20TransderFromMethod ¶
func ERC20TransferEvent ¶
func ERC20TransferMethod ¶
func ERC721InterfaceID ¶
func ERC721InterfaceID() [4]byte
func ERC721MetadataInterfaceID ¶
func ERC721MetadataInterfaceID() [4]byte
func ERC721MustEventIDs ¶
func ERC721MustEventIDs() map[string]struct{}
func ERC721MustMethodIDs ¶
func ERC721MustMethodIDs() map[string]struct{}
func EthereumAddress ¶
func NetworkStrings ¶
func NetworkStrings() []string
NetworkStrings returns a slice of all String values of the enum
func USDContractAddress ¶
func USDDecimals ¶
func ZeroAddress ¶
func ZeroBigInt ¶
Types ¶
type Network ¶
type Network int64
const ( NetworkEthereum Network = 1 NetworkGoerli Network = 5 NetworkOptimism Network = 10 NetworkBSC Network = 56 NetworkEthereumClassic Network = 61 NetworkPolygon Network = 137 NetworkBase Network = 8453 NetworkArbitrumOne Network = 42161 NetworkArbitrumNova Network = 42170 NetworkBaseGoerli Network = 84531 )
func NetworkString ¶
NetworkString retrieves an enum value from the enum constants string name. Throws an error if the param is not part of the enum.
func (Network) IsANetwork ¶
IsANetwork returns "true" if the value is listed in the enum definition. "false" otherwise
func (Network) MarshalJSON ¶
MarshalJSON implements the json.Marshaler interface for Network
func (*Network) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaler interface for Network
Source Files
¶
Click to show internal directories.
Click to hide internal directories.