adapters

package
v0.76.0 Latest Latest
Warning

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

Go to latest
Published: Jan 22, 2026 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ChainAccessAdapter

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

ChainAccessAdapter adapts CLDF's chain.BlockChains into a selector + lookup style API. It is used to make it compatible with the mcms lib chain access interface.

func Wrap

Wrap returns a ChainAccessAdapter adapter around the given CLDF BlockChains.

func (*ChainAccessAdapter) AptosClient

func (a *ChainAccessAdapter) AptosClient(selector uint64) (aptoslib.AptosRpcClient, bool)

AptosClient returns the Aptos RPC client for the given selector.

func (*ChainAccessAdapter) EVMClient

func (a *ChainAccessAdapter) EVMClient(selector uint64) (evm.ContractDeployBackend, bool)

EVMClient returns an EVM client for the given selector.

func (*ChainAccessAdapter) Selectors

func (a *ChainAccessAdapter) Selectors() []uint64

Selectors returns all known chain selectors (sorted by CLDF).

func (*ChainAccessAdapter) SolanaClient

func (a *ChainAccessAdapter) SolanaClient(selector uint64) (*solrpc.Client, bool)

SolanaClient returns the Solana RPC client for the given selector.

func (*ChainAccessAdapter) SuiClient

func (a *ChainAccessAdapter) SuiClient(selector uint64) (sui.ISuiAPI, mcmssui.SuiSigner, bool)

SuiClient returns the Sui API client and signer for the given selector.

type ChainsFetcher

type ChainsFetcher interface {
	ListChainSelectors(options ...chain.ChainSelectorsOption) []uint64
	EVMChains() map[uint64]cldfevm.Chain
	SolanaChains() map[uint64]cldfsol.Chain
	AptosChains() map[uint64]cldfaptos.Chain
	SuiChains() map[uint64]cldfsui.Chain
}

Jump to

Keyboard shortcuts

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