contract

package
v0.1.10 Latest Latest
Warning

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

Go to latest
Published: Jun 19, 2024 License: GPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BoundFeeOracleV1

type BoundFeeOracleV1 struct {
	// contains filtered or unexported fields
}

func New

New creates a new bound FeeOracleV1 contract.

func (BoundFeeOracleV1) GasPriceOn

func (c BoundFeeOracleV1) GasPriceOn(ctx context.Context, destChainID uint64) (*big.Int, error)

GasPriceOn returns the gas price on the FeeOracleV1 contract for the destination chain.

func (BoundFeeOracleV1) SetGasPriceOn

func (c BoundFeeOracleV1) SetGasPriceOn(ctx context.Context, destChainID uint64, gasPrice *big.Int) error

SetGasPriceOn sets the gas price on the FeeOracleV1 contract for the destination chain.

func (BoundFeeOracleV1) SetToNativeRate

func (c BoundFeeOracleV1) SetToNativeRate(ctx context.Context, destChainID uint64, rate *big.Int) error

setToNativeRate sets the conversion rate on the FeeOracleV1 contract for the destination chain.

func (BoundFeeOracleV1) ToNativeRate

func (c BoundFeeOracleV1) ToNativeRate(ctx context.Context, destChainID uint64) (*big.Int, error)

ToNativeRate returns the "to native" conversion rate on the FeeOracleV1 contract for the destination chaink.

type FeeOracleV1

type FeeOracleV1 interface {
	SetGasPriceOn(ctx context.Context, destChainID uint64, gasPrice *big.Int) error
	GasPriceOn(ctx context.Context, destChainID uint64) (*big.Int, error)

	SetToNativeRate(ctx context.Context, destChainID uint64, rate *big.Int) error
	ToNativeRate(ctx context.Context, destChainID uint64) (*big.Int, error)
}

type MockFeeOracleV1

type MockFeeOracleV1 struct {
	// contains filtered or unexported fields
}

func NewMockFeeOracleV1

func NewMockFeeOracleV1() *MockFeeOracleV1

func (*MockFeeOracleV1) GasPriceOn

func (m *MockFeeOracleV1) GasPriceOn(_ context.Context, destChainID uint64) (*big.Int, error)

func (*MockFeeOracleV1) SetGasPriceOn

func (m *MockFeeOracleV1) SetGasPriceOn(_ context.Context, destChainID uint64, gasPrice *big.Int) error

func (*MockFeeOracleV1) SetToNativeRate

func (m *MockFeeOracleV1) SetToNativeRate(_ context.Context, destChainID uint64, rate *big.Int) error

func (*MockFeeOracleV1) ToNativeRate

func (m *MockFeeOracleV1) ToNativeRate(_ context.Context, destChainID uint64) (*big.Int, error)

Jump to

Keyboard shortcuts

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