chain

package
v1.17.0 Latest Latest
Warning

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

Go to latest
Published: Nov 14, 2024 License: Apache-2.0, MIT Imports: 60 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrMetadataNotFound = errors.New("actor metadata not found")

Functions

func NewAccountAPI

func NewAccountAPI(chain *ChainSubmodule) v1api.IAccount

NewAccountAPI create a new account api

func NewActorAPI

func NewActorAPI(chain *ChainSubmodule) v1api.IActor

NewActorAPI new actor api

func NewChainInfoAPI

func NewChainInfoAPI(chain *ChainSubmodule) v1api.IChainInfo

NewChainInfoAPI new chain info api

func NewMinerStateAPI

func NewMinerStateAPI(chain *ChainSubmodule) v1api.IMinerState

NewMinerStateAPI create miner state api

Types

type ChainSubmodule

type ChainSubmodule struct {
	ChainReader                 *chain.Store
	MessageStore                *chain.MessageStore
	Processor                   *consensus.DefaultProcessor
	Fork                        fork.IFork
	SystemCall                  vm.SyscallsImpl
	CirculatingSupplyCalculator *chain.CirculatingSupplyCalculator

	CheckPoint types.TipSetKey
	Drand      beacon.Schedule

	Stmgr *statemanger.Stmgr
	// Wait for confirm message
	Waiter *chain.Waiter
	// contains filtered or unexported fields
}

ChainSubmodule enhances the `Node` with chain capabilities.

func NewChainSubmodule

func NewChainSubmodule(ctx context.Context,
	config chainConfig,
) (*ChainSubmodule, error)

NewChainSubmodule creates a new chain submodule.

func (*ChainSubmodule) API

func (chain *ChainSubmodule) API() v1api.IChain

API chain module api implement

func (*ChainSubmodule) Start

func (chain *ChainSubmodule) Start(ctx context.Context) error

Start loads the chain from disk.

func (*ChainSubmodule) Stop

func (chain *ChainSubmodule) Stop(ctx context.Context)

Stop stop the chain head event

func (*ChainSubmodule) V0API added in v0.9.7

func (chain *ChainSubmodule) V0API() v0api.IChain

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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