Documentation
¶
Index ¶
- Constants
- Variables
- func MakeEmptyPendingDataForParent(bcReader blockchain.Reader, latestHeader *core.Header) (core.PendingData, error)
- func MakeEmptyPendingForParent(bcReader blockchain.Reader, latestHeader *core.Header) (core.Pending, error)
- func MakeEmptyPreConfirmedForParent(bcReader blockchain.Reader, latestHeader *core.Header) (core.PreConfirmed, error)
- func NeedsPreConfirmed(protocolVersion string) (bool, error)
- func PendingState(pending core.PendingData, stateReader blockchain.Reader) (core.StateReader, blockchain.StateCloser, error)
- func PendingStateBeforeIndex(pending core.PendingData, stateReader blockchain.Reader, index uint) (core.StateReader, blockchain.StateCloser, error)
- func ResolvePendingBaseState(pending *core.Pending, stateReader blockchain.Reader) (core.StateReader, blockchain.StateCloser, error)
- func ResolvePendingDataBaseState(pending core.PendingData, stateReader blockchain.Reader) (core.StateReader, blockchain.StateCloser, error)
- func ResolvePreConfirmedBaseState(preConfirmed *core.PreConfirmed, stateReader blockchain.Reader) (core.StateReader, blockchain.StateCloser, error)
Constants ¶
View Source
const BlockHashLag uint64 = 10
Variables ¶
View Source
var ( BlockHashStorageContract = &felt.One ErrUnsupportedPendingDataVariant = errors.New("unsupported pending data variant") )
Functions ¶
func MakeEmptyPendingDataForParent ¶
func MakeEmptyPendingDataForParent( bcReader blockchain.Reader, latestHeader *core.Header, ) (core.PendingData, error)
func MakeEmptyPreConfirmedForParent ¶
func MakeEmptyPreConfirmedForParent( bcReader blockchain.Reader, latestHeader *core.Header, ) (core.PreConfirmed, error)
func NeedsPreConfirmed ¶
needsPreConfirmed reports whether the given protocol version string indicates blocks >= v0.14.0 (i.e., pre_confirmed path is required).
func PendingState ¶
func PendingState( pending core.PendingData, stateReader blockchain.Reader, ) (core.StateReader, blockchain.StateCloser, error)
PendingState is a convenience function that combines base state resolution with pending state creation
func PendingStateBeforeIndex ¶
func PendingStateBeforeIndex( pending core.PendingData, stateReader blockchain.Reader, index uint, ) (core.StateReader, blockchain.StateCloser, error)
PendingStateBeforeIndex is a convenience function that combines base state resolution with pending state before index creation
func ResolvePendingBaseState ¶
func ResolvePendingBaseState( pending *core.Pending, stateReader blockchain.Reader, ) (core.StateReader, blockchain.StateCloser, error)
func ResolvePendingDataBaseState ¶
func ResolvePendingDataBaseState( pending core.PendingData, stateReader blockchain.Reader, ) (core.StateReader, blockchain.StateCloser, error)
ResolvePendingDataBaseState determines the appropriate base state for pending data and returns the state reader along with its closer function.
func ResolvePreConfirmedBaseState ¶
func ResolvePreConfirmedBaseState( preConfirmed *core.PreConfirmed, stateReader blockchain.Reader, ) (core.StateReader, blockchain.StateCloser, error)
ResolvePreConfirmedBaseState resolves the base state for pre-confirmed blocks
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.