Documentation ¶
Index ¶
- func NewProvider() module.Provider[*engine.Engine, notarization.Notarization]
- type Manager
- func (m *Manager) AcceptedBlocksCount(index iotago.SlotIndex) int
- func (m *Manager) ForceCommit(slot iotago.SlotIndex) (*model.Commitment, error)
- func (m *Manager) ForceCommitUntil(commitUntilSlot iotago.SlotIndex) error
- func (m *Manager) IsBootstrapped() bool
- func (m *Manager) Reset()
- func (m *Manager) Shutdown()
- type SlotMutations
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewProvider ¶
func NewProvider() module.Provider[*engine.Engine, notarization.Notarization]
Types ¶
type Manager ¶
type Manager struct { // ForceCommitMode contains a flag that indicates whether the manager is in force commit mode. ForceCommitMode atomic.Bool module.Module // contains filtered or unexported fields }
Manager is the component that manages the slot commitments.
func (*Manager) AcceptedBlocksCount ¶
func (*Manager) ForceCommit ¶
func (*Manager) ForceCommitUntil ¶
func (*Manager) IsBootstrapped ¶
IsBootstrapped returns if the Manager finished committing all pending slots up to the current acceptance time.
type SlotMutations ¶
type SlotMutations struct {
// contains filtered or unexported fields
}
SlotMutations is an in-memory data structure that enables the collection of mutations for uncommitted slots.
func NewSlotMutations ¶
func NewSlotMutations(lastCommittedSlot iotago.SlotIndex) *SlotMutations
NewSlotMutations creates a new SlotMutations instance.
func (*SlotMutations) AcceptedBlocksCount ¶
func (m *SlotMutations) AcceptedBlocksCount(index iotago.SlotIndex) int
func (*SlotMutations) AddAcceptedBlock ¶
func (m *SlotMutations) AddAcceptedBlock(block *blocks.Block) (err error)
AddAcceptedBlock adds the given block to the set of accepted blocks.
func (*SlotMutations) Commit ¶
func (m *SlotMutations) Commit(slot iotago.SlotIndex) (ads.Set[iotago.Identifier, iotago.BlockID], error)
func (*SlotMutations) Reset ¶
func (m *SlotMutations) Reset()
Reset resets the component to a clean state as if it was created at the last commitment.
Click to show internal directories.
Click to hide internal directories.