quaiclient

package
v0.27.1 Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2023 License: GPL-3.0 Imports: 8 Imported by: 3

Documentation

Overview

Package ethclient provides a client for the Quai RPC API.

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 defines typed wrappers for the Quai RPC API.

func Dial

func Dial(rawurl string) (*Client, error)

Dial connects a client to the given URL.

func DialContext

func DialContext(ctx context.Context, rawurl string) (*Client, error)

func NewClient

func NewClient(c *rpc.Client) *Client

NewClient creates a client that uses the given RPC client.

func (*Client) Append

func (ec *Client) Append(ctx context.Context, header *types.Header, manifest types.BlockManifest, domPendingHeader *types.Header, domTerminus common.Hash, domOrigin bool, newInboundEtxs types.Transactions) (types.Transactions, bool, bool, error)

func (*Client) Close

func (ec *Client) Close()

func (*Client) DownloadBlocksInManifest added in v0.19.0

func (ec *Client) DownloadBlocksInManifest(ctx context.Context, hash common.Hash, manifest types.BlockManifest, entropy *big.Int)

func (*Client) GenerateRecoveryPendingHeader

func (ec *Client) GenerateRecoveryPendingHeader(ctx context.Context, pendingHeader *types.Header, checkpointHashes types.Termini) error

func (*Client) GetManifest

func (ec *Client) GetManifest(ctx context.Context, blockHash common.Hash) (types.BlockManifest, error)

GetManifest will get the block manifest ending with the parent hash

func (*Client) GetPendingEtxsFromSub added in v0.19.0

func (ec *Client) GetPendingEtxsFromSub(ctx context.Context, hash common.Hash, location common.Location) (types.PendingEtxs, error)

GetPendingEtxsFromSub gets the pendingEtxsRollup from the region

func (*Client) GetPendingEtxsRollupFromSub added in v0.19.0

func (ec *Client) GetPendingEtxsRollupFromSub(ctx context.Context, hash common.Hash, location common.Location) (types.PendingEtxsRollup, error)

GetPendingEtxsRollupFromSub gets the pendingEtxsRollup from the region

func (*Client) HeaderByHash

func (ec *Client) HeaderByHash(ctx context.Context, hash common.Hash) *types.Header

func (*Client) HeaderByNumber

func (ec *Client) HeaderByNumber(ctx context.Context, number string) *types.Header

func (*Client) NewGenesisPendingHeader

func (ec *Client) NewGenesisPendingHeader(ctx context.Context, header *types.Header)

func (*Client) RequestDomToAppendOrFetch

func (ec *Client) RequestDomToAppendOrFetch(ctx context.Context, hash common.Hash, entropy *big.Int, order int)

func (*Client) SendPendingEtxsRollupToDom

func (ec *Client) SendPendingEtxsRollupToDom(ctx context.Context, pEtxsRollup types.PendingEtxsRollup) error

func (*Client) SendPendingEtxsToDom

func (ec *Client) SendPendingEtxsToDom(ctx context.Context, pEtxs types.PendingEtxs) error

func (*Client) SetSyncTarget added in v0.21.0

func (ec *Client) SetSyncTarget(ctx context.Context, header *types.Header)

func (*Client) SubRelayPendingHeader

func (ec *Client) SubRelayPendingHeader(ctx context.Context, pendingHeader types.PendingHeader, newEntropy *big.Int, location common.Location, subReorg bool, order int)

func (*Client) UpdateDom

func (ec *Client) UpdateDom(ctx context.Context, oldTerminus common.Hash, pendingHeader types.PendingHeader, location common.Location)

type Termini

type Termini struct {
	Termini []common.Hash `json:"termini"`
}

Directories

Path Synopsis
Package ethclient provides a client for the Quai RPC API.
Package ethclient provides a client for the Quai RPC API.

Jump to

Keyboard shortcuts

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