finalizeblock

package
v0.0.0-...-f4c8e74 Latest Latest
Warning

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

Go to latest
Published: Apr 2, 2025 License: AGPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type EventStager

type EventStager[T proto.Message] struct {
	// contains filtered or unexported fields
}

EventStager supports staging and retrieval of events (of type T) from FinalizeBlock.

func NewEventStager

func NewEventStager[T proto.Message](
	transientStoreKey storetypes.StoreKey,
	cdc codec.BinaryCodec,
	stagedEventCountKey string,
	stagedEventKeyPrefix string,
) EventStager[T]

NewEventStager creates a new EventStager.

func (EventStager[T]) GetStagedFinalizeBlockEvents

func (s EventStager[T]) GetStagedFinalizeBlockEvents(
	ctx sdk.Context,
	newStagedEvent func() T,
) []T

GetStagedFinalizeBlockEvents retrieves all staged events from the store.

func (EventStager[T]) StageFinalizeBlockEvent

func (s EventStager[T]) StageFinalizeBlockEvent(
	ctx sdk.Context,
	stagedEvent T,
)

StageFinalizeBlockEvent stages an event in the transient store.

Jump to

Keyboard shortcuts

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