starknet

package
v1.13.0-healthchecks-2... Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2023 License: MIT Imports: 25 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewORMImmut added in v1.10.0

Types

type ChainSet

type ChainSet interface {
	starkchain.ChainSet
	chains.Chains[string, *db.ChainCfg]
	chains.Nodes[string, db.Node]
}

func NewChainSetImmut added in v1.10.0

func NewChainSetImmut(opts ChainSetOpts, cfgs StarknetConfigs) (ChainSet, error)

type ChainSetOpts

type ChainSetOpts struct {
	Config   coreconfig.BasicConfig
	Logger   logger.Logger
	KeyStore keystore.StarkNet
	ORM      types.ORM
}

func (*ChainSetOpts) Name added in v1.13.0

func (o *ChainSetOpts) Name() string

func (*ChainSetOpts) NewChain

func (o *ChainSetOpts) NewChain(cc types.ChainConfig) (starkchain.Chain, error)

func (*ChainSetOpts) NewTOMLChain added in v1.10.0

func (o *ChainSetOpts) NewTOMLChain(cfg *StarknetConfig) (starkchain.Chain, error)

func (*ChainSetOpts) ORMAndLogger

func (o *ChainSetOpts) ORMAndLogger() (chains.ORM[string, *db.ChainCfg, db.Node], logger.Logger)

func (*ChainSetOpts) Validate

func (o *ChainSetOpts) Validate() (err error)

type StarknetConfig added in v1.10.0

type StarknetConfig struct {
	ChainID *string
	Enabled *bool
	stkcfg.Chain
	Nodes StarknetNodes
}

func (*StarknetConfig) AsV1 added in v1.10.0

func (c *StarknetConfig) AsV1() types.ChainConfig

func (*StarknetConfig) IsEnabled added in v1.10.0

func (c *StarknetConfig) IsEnabled() bool

func (*StarknetConfig) OCR2CachePollPeriod added in v1.10.0

func (c *StarknetConfig) OCR2CachePollPeriod() time.Duration

func (*StarknetConfig) OCR2CacheTTL added in v1.10.0

func (c *StarknetConfig) OCR2CacheTTL() time.Duration

func (*StarknetConfig) RequestTimeout added in v1.10.0

func (c *StarknetConfig) RequestTimeout() time.Duration

func (*StarknetConfig) SetFrom added in v1.11.0

func (c *StarknetConfig) SetFrom(f *StarknetConfig)

func (*StarknetConfig) SetFromDB added in v1.10.0

func (c *StarknetConfig) SetFromDB(ch types.ChainConfig, nodes []db.Node) error

func (*StarknetConfig) TxMaxBatchSize added in v1.10.0

func (c *StarknetConfig) TxMaxBatchSize() int

func (*StarknetConfig) TxSendFrequency added in v1.10.0

func (c *StarknetConfig) TxSendFrequency() time.Duration

func (*StarknetConfig) TxTimeout added in v1.10.0

func (c *StarknetConfig) TxTimeout() time.Duration

func (*StarknetConfig) ValidateConfig added in v1.10.0

func (c *StarknetConfig) ValidateConfig() (err error)

type StarknetConfigs added in v1.10.0

type StarknetConfigs []*StarknetConfig

func (StarknetConfigs) Chains added in v1.10.0

func (cs StarknetConfigs) Chains(ids ...string) (chains []types.ChainConfig)

func (StarknetConfigs) Node added in v1.10.0

func (cs StarknetConfigs) Node(name string) (n db.Node, err error)

func (StarknetConfigs) Nodes added in v1.10.0

func (cs StarknetConfigs) Nodes() (ns []db.Node)

func (StarknetConfigs) NodesByID added in v1.10.0

func (cs StarknetConfigs) NodesByID(chainIDs ...string) (ns []db.Node)

func (*StarknetConfigs) SetFrom added in v1.11.0

func (cs *StarknetConfigs) SetFrom(fs *StarknetConfigs)

func (StarknetConfigs) ValidateConfig added in v1.10.0

func (cs StarknetConfigs) ValidateConfig() (err error)

type StarknetNodes added in v1.10.0

type StarknetNodes []*stkcfg.Node

func (*StarknetNodes) SetFrom added in v1.11.0

func (ns *StarknetNodes) SetFrom(fs *StarknetNodes)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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