chaintype

package
v2.14.0-beta0 Latest Latest
Warning

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

Go to latest
Published: Jul 3, 2024 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

Functions

This section is empty.

Types

type ChainType

type ChainType string
const (
	ChainArbitrum        ChainType = "arbitrum"
	ChainCelo            ChainType = "celo"
	ChainGnosis          ChainType = "gnosis"
	ChainKroma           ChainType = "kroma"
	ChainMetis           ChainType = "metis"
	ChainOptimismBedrock ChainType = "optimismBedrock"
	ChainScroll          ChainType = "scroll"
	ChainWeMix           ChainType = "wemix"
	ChainXLayer          ChainType = "xlayer"
	ChainZkEvm           ChainType = "zkevm"
	ChainZkSync          ChainType = "zksync"
)

func ChainTypeFromSlug

func ChainTypeFromSlug(slug string) ChainType

func (ChainType) IsL2

func (c ChainType) IsL2() bool

IsL2 returns true if this chain is a Layer 2 chain. Notably:

  • the block numbers used for log searching are different from calling block.number
  • gas bumping is not supported, since there is no tx mempool

func (ChainType) IsValid

func (c ChainType) IsValid() bool

type ChainTypeConfig

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

func NewChainTypeConfig

func NewChainTypeConfig(slug string) *ChainTypeConfig

func (*ChainTypeConfig) ChainType

func (c *ChainTypeConfig) ChainType() ChainType

func (*ChainTypeConfig) MarshalText

func (c *ChainTypeConfig) MarshalText() ([]byte, error)

func (*ChainTypeConfig) Slug

func (c *ChainTypeConfig) Slug() string

func (*ChainTypeConfig) String

func (c *ChainTypeConfig) String() string

func (*ChainTypeConfig) UnmarshalText

func (c *ChainTypeConfig) UnmarshalText(b []byte) error

Jump to

Keyboard shortcuts

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