Versions in this module Expand all Collapse all v0 v0.1.1 Oct 7, 2021 v0.1.0 Sep 30, 2021 Changes in this version + const GenesisTestAddr + const GenesisTestKey + var Codec codec.Manager + var EVMInputGas uint64 = (common.AddressLength+wrappers.LongLen+hashing.HashLen+wrappers.LongLen)*TxBytesGas + secp256k1fx.CostPerSignature + var EVMOutputGas uint64 = (common.AddressLength + wrappers.LongLen + hashing.HashLen) * TxBytesGas + var GitCommit string + var ID = ids.ID + var TxBytesGas uint64 = 1 + var Version string + func FormatEthAddress(addr common.Address) string + func GetEthAddress(privKey *crypto.PrivateKeySECP256K1R) common.Address + func IsSortedAndUniqueEVMInputs(inputs []EVMInput) bool + func IsSortedAndUniqueEVMOutputs(outputs []EVMOutput) bool + func IsSortedEVMOutputs(outputs []EVMOutput) bool + func ParseEthAddress(addrStr string) (common.Address, error) + func PublicKeyToEthAddress(pubKey *crypto.PublicKeySECP256K1R) common.Address + func SortEVMInputsAndSigners(inputs []EVMInput, signers [][]*crypto.PrivateKeySECP256K1R) + func SortEVMOutputs(outputs []EVMOutput) + type AvaxAPI struct + func (service *AvaxAPI) Export(_ *http.Request, args *ExportArgs, response *api.JSONTxID) error + func (service *AvaxAPI) ExportAVAX(_ *http.Request, args *ExportAVAXArgs, response *api.JSONTxID) error + func (service *AvaxAPI) ExportKey(r *http.Request, args *ExportKeyArgs, reply *ExportKeyReply) error + func (service *AvaxAPI) GetAtomicTx(r *http.Request, args *api.GetTxArgs, reply *FormattedTx) error + func (service *AvaxAPI) GetAtomicTxStatus(r *http.Request, args *api.JSONTxID, reply *GetAtomicTxStatusReply) error + func (service *AvaxAPI) GetUTXOs(r *http.Request, args *api.GetUTXOsArgs, reply *api.GetUTXOsReply) error + func (service *AvaxAPI) Import(_ *http.Request, args *ImportArgs, response *api.JSONTxID) error + func (service *AvaxAPI) ImportAVAX(_ *http.Request, args *ImportArgs, response *api.JSONTxID) error + func (service *AvaxAPI) ImportKey(r *http.Request, args *ImportKeyArgs, reply *api.JSONAddress) error + func (service *AvaxAPI) IssueTx(r *http.Request, args *api.FormattedTx, response *api.JSONTxID) error + func (service *AvaxAPI) Version(r *http.Request, args *struct{}, reply *VersionReply) error + type Batch struct + func (batch Batch) Replay(w ethdb.KeyValueWriter) error + func (batch Batch) ValueSize() int + type Block struct + func (b *Block) Accept() error + func (b *Block) Bytes() []byte + func (b *Block) Height() uint64 + func (b *Block) ID() ids.ID + func (b *Block) Parent() ids.ID + func (b *Block) Reject() error + func (b *Block) SetStatus(status choices.Status) + func (b *Block) Status() choices.Status + func (b *Block) String() string + func (b *Block) Timestamp() time.Time + func (b *Block) Verify() error + type BlockValidator interface + SyntacticVerify func(b *Block) error + type BuildGenesisReply struct + Bytes string + Encoding formatting.Encoding + type Client struct + func NewCChainClient(uri string, requestTimeout time.Duration) *Client + func NewClient(uri, chain string, requestTimeout time.Duration) *Client + func (c *Client) Export(user api.UserPass, amount uint64, to string, assetID string) (ids.ID, error) + func (c *Client) ExportAVAX(user api.UserPass, amount uint64, to string) (ids.ID, error) + func (c *Client) ExportKey(user api.UserPass, addr string) (string, string, error) + func (c *Client) GetAtomicTx(txID ids.ID) ([]byte, error) + func (c *Client) GetAtomicTxStatus(txID ids.ID) (Status, error) + func (c *Client) GetAtomicUTXOs(addrs []string, sourceChain string, limit uint32, ...) ([][]byte, api.Index, error) + func (c *Client) Import(user api.UserPass, to, sourceChain string) (ids.ID, error) + func (c *Client) ImportKey(user api.UserPass, privateKey string) (string, error) + func (c *Client) IssueTx(txBytes []byte) (ids.ID, error) + func (c *Client) ListAddresses(user api.UserPass) ([]string, error) + type Config struct + APIMaxDuration Duration + AllowUnfinalizedQueries bool + ContinuousProfilerDir string + ContinuousProfilerFrequency Duration + ContinuousProfilerMaxFiles int + CorethAdminAPIEnabled bool + DebugAPIEnabled bool + EthAPIEnabled bool + KeystoreDirectory string + KeystoreExternalSigner string + KeystoreInsecureUnlockAllowed bool + LocalTxsEnabled bool + MaxBlocksPerRequest int64 + NetAPIEnabled bool + PersonalAPIEnabled bool + Pruning bool + RPCGasCap uint64 + RPCTxFeeCap float64 + SnapshotAsync bool + SnapshotVerify bool + SnowmanAPIEnabled bool + TxPoolAPIEnabled bool + Web3APIEnabled bool + func (c *Config) SetDefaults() + func (c Config) EthAPIs() []string + func (c Config) EthBackendSettings() eth.Settings + type Database struct + func (db Database) Ancient(kind string, number uint64) ([]byte, error) + func (db Database) AncientSize(kind string) (uint64, error) + func (db Database) Ancients() (uint64, error) + func (db Database) AppendAncient(number uint64, hash, header, body, receipts, td []byte) error + func (db Database) HasAncient(kind string, number uint64) (bool, error) + func (db Database) NewBatch() ethdb.Batch + func (db Database) NewIterator(prefix []byte, start []byte) ethdb.Iterator + func (db Database) NewIteratorWithStart(start []byte) ethdb.Iterator + func (db Database) Sync() error + func (db Database) TruncateAncients(items uint64) error + type Duration struct + func (d *Duration) UnmarshalJSON(data []byte) (err error) + type EVMInput struct + Address common.Address + Amount uint64 + AssetID ids.ID + Nonce uint64 + func (in *EVMInput) Verify() error + type EVMOutput struct + Address common.Address + Amount uint64 + AssetID ids.ID + func (out *EVMOutput) Verify() error + type ExportAVAXArgs struct + Amount json.Uint64 + BaseFee *hexutil.Big + To string + type ExportArgs struct + AssetID string + type ExportKeyArgs struct + Address string + type ExportKeyReply struct + PrivateKey string + PrivateKeyHex string + type Factory struct + func (f *Factory) New(*snow.Context) (interface{}, error) + type FormattedTx struct + BlockHeight *json.Uint64 + type GetAcceptedFrontReply struct + Hash common.Hash + Number *big.Int + type GetAtomicTxStatusReply struct + BlockHeight *json.Uint64 + Status Status + type ImportArgs struct + BaseFee *hexutil.Big + SourceChain string + To string + type ImportKeyArgs struct + PrivateKey string + type Mempool struct + Pending chan struct{} + func NewMempool(maxSize int) *Mempool + func (m *Mempool) AddTx(tx *Tx) error + func (m *Mempool) CancelCurrentTx() + func (m *Mempool) DiscardCurrentTx() + func (m *Mempool) GetTx(txID ids.ID) (*Tx, bool, bool) + func (m *Mempool) IssueCurrentTx() + func (m *Mempool) Len() int + func (m *Mempool) NextTx() (*Tx, bool) + func (m *Mempool) RejectTx(txID ids.ID) + func (m *Mempool) RemoveTx(txID ids.ID) + type NetAPI struct + func (s *NetAPI) Listening() bool + func (s *NetAPI) PeerCount() hexutil.Uint + func (s *NetAPI) Version() string + type Performance struct + func NewPerformanceService(dir string) *Performance + func (p *Performance) LockProfile(ctx context.Context) (bool, error) + func (p *Performance) MemoryProfile(ctx context.Context) (bool, error) + func (p *Performance) StartCPUProfiler(ctx context.Context) (bool, error) + func (p *Performance) StopCPUProfiler(ctx context.Context) (bool, error) + type SnowmanAPI struct + func (api *SnowmanAPI) GetAcceptedFront(ctx context.Context) (*GetAcceptedFrontReply, error) + func (api *SnowmanAPI) IssueBlock(ctx context.Context) error + type StaticService struct + func (*StaticService) BuildGenesis(_ context.Context, args *core.Genesis) (*BuildGenesisReply, error) + type Status uint32 + const Accepted + const Dropped + const Processing + const Unknown + func (s *Status) UnmarshalJSON(b []byte) error + func (s Status) MarshalJSON() ([]byte, error) + func (s Status) String() string + func (s Status) Valid() error + type Tx struct + Creds []verify.Verifiable + func (tx *Tx) Sign(c codec.Manager, signers [][]*crypto.PrivateKeySECP256K1R) error + type UnsignedAtomicTx interface + Accept func(ctx *snow.Context, batch database.Batch) error + EVMStateTransfer func(ctx *snow.Context, state *state.StateDB) error + InputUTXOs func() ids.Set + SemanticVerify func(vm *VM, stx *Tx, parent *Block, baseFee *big.Int, rules params.Rules) error + type UnsignedExportTx struct + BlockchainID ids.ID + DestinationChain ids.ID + ExportedOutputs []*avax.TransferableOutput + Ins []EVMInput + NetworkID uint32 + func (tx *UnsignedExportTx) Accept(ctx *snow.Context, batch database.Batch) error + func (tx *UnsignedExportTx) Burned(assetID ids.ID) (uint64, error) + func (tx *UnsignedExportTx) Cost() (uint64, error) + func (tx *UnsignedExportTx) EVMStateTransfer(ctx *snow.Context, state *state.StateDB) error + func (tx *UnsignedExportTx) InputUTXOs() ids.Set + func (tx *UnsignedExportTx) SemanticVerify(vm *VM, stx *Tx, _ *Block, baseFee *big.Int, rules params.Rules) error + func (tx *UnsignedExportTx) Verify(avmID ids.ID, ctx *snow.Context, rules params.Rules) error + type UnsignedImportTx struct + BlockchainID ids.ID + ImportedInputs []*avax.TransferableInput + NetworkID uint32 + Outs []EVMOutput + SourceChain ids.ID + func (tx *UnsignedImportTx) Accept(ctx *snow.Context, batch database.Batch) error + func (tx *UnsignedImportTx) Burned(assetID ids.ID) (uint64, error) + func (tx *UnsignedImportTx) Cost() (uint64, error) + func (tx *UnsignedImportTx) EVMStateTransfer(ctx *snow.Context, state *state.StateDB) error + func (tx *UnsignedImportTx) InputUTXOs() ids.Set + func (tx *UnsignedImportTx) SemanticVerify(vm *VM, stx *Tx, parent *Block, baseFee *big.Int, rules params.Rules) error + func (tx *UnsignedImportTx) Verify(avmID ids.ID, ctx *snow.Context, rules params.Rules) error + type UnsignedTx interface + Bytes func() []byte + Cost func() (uint64, error) + ID func() ids.ID + Initialize func(unsignedBytes, signedBytes []byte) + UnsignedBytes func() []byte + type VM struct + func (vm *VM) Bootstrapped() error + func (vm *VM) Bootstrapping() error + func (vm *VM) Clock() *timer.Clock + func (vm *VM) Codec() codec.Manager + func (vm *VM) CodecRegistry() codec.Registry + func (vm *VM) Connected(id ids.ShortID) error + func (vm *VM) CreateHandlers() (map[string]*commonEng.HTTPHandler, error) + func (vm *VM) CreateStaticHandlers() (map[string]*commonEng.HTTPHandler, error) + func (vm *VM) Disconnected(id ids.ShortID) error + func (vm *VM) FormatAddress(chainID ids.ID, addr ids.ShortID) (string, error) + func (vm *VM) FormatLocalAddress(addr ids.ShortID) (string, error) + func (vm *VM) GetAtomicUTXOs(chainID ids.ID, addrs ids.ShortSet, startAddr ids.ShortID, startUTXOID ids.ID, ...) ([]*avax.UTXO, ids.ShortID, ids.ID, error) + func (vm *VM) GetCurrentNonce(address common.Address) (uint64, error) + func (vm *VM) GetSpendableAVAXWithFee(keys []*crypto.PrivateKeySECP256K1R, amount uint64, cost uint64, ...) ([]EVMInput, [][]*crypto.PrivateKeySECP256K1R, error) + func (vm *VM) GetSpendableFunds(keys []*crypto.PrivateKeySECP256K1R, assetID ids.ID, amount uint64) ([]EVMInput, [][]*crypto.PrivateKeySECP256K1R, error) + func (vm *VM) HealthCheck() (interface{}, error) + func (vm *VM) Initialize(ctx *snow.Context, dbManager manager.Manager, genesisBytes []byte, ...) error + func (vm *VM) Logger() logging.Logger + func (vm *VM) ParseAddress(addrStr string) (ids.ID, ids.ShortID, error) + func (vm *VM) ParseLocalAddress(addrStr string) (ids.ShortID, error) + func (vm *VM) SetPreference(blkID ids.ID) error + func (vm *VM) Shutdown() error + func (vm *VM) Version() (string, error) + type VersionReply struct + Version string + type Web3API struct + func (s *Web3API) ClientVersion() string + func (s *Web3API) Sha3(input hexutil.Bytes) hexutil.Bytes