Versions in this module Expand all Collapse all v1 v1.11.10 Jul 13, 2024 Changes in this version + const CodecVersion0 + const CodecVersion0Tag + const CodecVersion1 + const CodecVersion1Tag + var BlockIDPrefix = []byte("blockID") + var BlockPrefix = []byte("block") + var BlocksReindexedKey = []byte("blocks reindexed") + var ChainPrefix = []byte("chain") + var CurrentPrefix = []byte("current") + var CurrentSupplyKey = []byte("current supply") + var DelegatorPrefix = []byte("delegator") + var ErrMissingParentState = errors.New("missing parent state") + var HeightsIndexedKey = []byte("heights indexed") + var InitializedKey = []byte("initialized") + var LastAcceptedKey = []byte("last accepted") + var MetadataCodec codec.Manager + var PendingPrefix = []byte("pending") + var RewardUTXOsPrefix = []byte("rewardUTXOs") + var SingletonPrefix = []byte("singleton") + var SubnetDelegatorPrefix = []byte("subnetDelegator") + var SubnetOwnerPrefix = []byte("subnetOwner") + var SubnetPrefix = []byte("subnet") + var SubnetValidatorPrefix = []byte("subnetValidator") + var SupplyPrefix = []byte("supply") + var TimestampKey = []byte("timestamp") + var TransformedSubnetPrefix = []byte("transformedSubnet") + var TxPrefix = []byte("tx") + var UTXOPrefix = []byte("utxo") + var ValidatorPrefix = []byte("validator") + var ValidatorPublicKeyDiffsPrefix = []byte("flatPublicKeyDiffs") + var ValidatorWeightDiffsPrefix = []byte("flatValidatorDiffs") + var ValidatorsPrefix = []byte("validators") + func GetNextStakerChangeTime(state Chain) (time.Time, error) + func NextBlockTime(state Chain, clk *mockable.Clock) (time.Time, bool, error) + type Chain interface + AddChain func(createChainTx *txs.Tx) + AddRewardUTXO func(txID ids.ID, utxo *lux.UTXO) + AddSubnet func(subnetID ids.ID) + AddSubnetTransformation func(transformSubnetTx *txs.Tx) + AddTx func(tx *txs.Tx, status status.Status) + GetCurrentSupply func(subnetID ids.ID) (uint64, error) + GetSubnetOwner func(subnetID ids.ID) (fx.Owner, error) + GetSubnetTransformation func(subnetID ids.ID) (*txs.Tx, error) + GetTimestamp func() time.Time + GetTx func(txID ids.ID) (*txs.Tx, status.Status, error) + SetCurrentSupply func(subnetID ids.ID, cs uint64) + SetSubnetOwner func(subnetID ids.ID, owner fx.Owner) + SetTimestamp func(tm time.Time) + type CurrentStakers interface + DeleteCurrentDelegator func(staker *Staker) + DeleteCurrentValidator func(staker *Staker) + GetCurrentDelegatorIterator func(subnetID ids.ID, nodeID ids.NodeID) (StakerIterator, error) + GetCurrentStakerIterator func() (StakerIterator, error) + GetCurrentValidator func(subnetID ids.ID, nodeID ids.NodeID) (*Staker, error) + GetDelegateeReward func(subnetID ids.ID, nodeID ids.NodeID) (uint64, error) + PutCurrentDelegator func(staker *Staker) + PutCurrentValidator func(staker *Staker) + SetDelegateeReward func(subnetID ids.ID, nodeID ids.NodeID, amount uint64) error + type Diff interface + Apply func(Chain) error + func NewDiff(parentID ids.ID, stateVersions Versions) (Diff, error) + func NewDiffOn(parentState Chain) (Diff, error) + type MockChain struct + func NewMockChain(ctrl *gomock.Controller) *MockChain + func (m *MockChain) AddChain(arg0 *txs.Tx) + func (m *MockChain) AddRewardUTXO(arg0 ids.ID, arg1 *lux.UTXO) + func (m *MockChain) AddSubnet(arg0 ids.ID) + func (m *MockChain) AddSubnetTransformation(arg0 *txs.Tx) + func (m *MockChain) AddTx(arg0 *txs.Tx, arg1 status.Status) + func (m *MockChain) AddUTXO(arg0 *lux.UTXO) + func (m *MockChain) DeleteCurrentDelegator(arg0 *Staker) + func (m *MockChain) DeleteCurrentValidator(arg0 *Staker) + func (m *MockChain) DeletePendingDelegator(arg0 *Staker) + func (m *MockChain) DeletePendingValidator(arg0 *Staker) + func (m *MockChain) DeleteUTXO(arg0 ids.ID) + func (m *MockChain) EXPECT() *MockChainMockRecorder + func (m *MockChain) GetCurrentDelegatorIterator(arg0 ids.ID, arg1 ids.NodeID) (StakerIterator, error) + func (m *MockChain) GetCurrentStakerIterator() (StakerIterator, error) + func (m *MockChain) GetCurrentSupply(arg0 ids.ID) (uint64, error) + func (m *MockChain) GetCurrentValidator(arg0 ids.ID, arg1 ids.NodeID) (*Staker, error) + func (m *MockChain) GetDelegateeReward(arg0 ids.ID, arg1 ids.NodeID) (uint64, error) + func (m *MockChain) GetPendingDelegatorIterator(arg0 ids.ID, arg1 ids.NodeID) (StakerIterator, error) + func (m *MockChain) GetPendingStakerIterator() (StakerIterator, error) + func (m *MockChain) GetPendingValidator(arg0 ids.ID, arg1 ids.NodeID) (*Staker, error) + func (m *MockChain) GetSubnetOwner(arg0 ids.ID) (fx.Owner, error) + func (m *MockChain) GetSubnetTransformation(arg0 ids.ID) (*txs.Tx, error) + func (m *MockChain) GetTimestamp() time.Time + func (m *MockChain) GetTx(arg0 ids.ID) (*txs.Tx, status.Status, error) + func (m *MockChain) GetUTXO(arg0 ids.ID) (*lux.UTXO, error) + func (m *MockChain) PutCurrentDelegator(arg0 *Staker) + func (m *MockChain) PutCurrentValidator(arg0 *Staker) + func (m *MockChain) PutPendingDelegator(arg0 *Staker) + func (m *MockChain) PutPendingValidator(arg0 *Staker) + func (m *MockChain) SetCurrentSupply(arg0 ids.ID, arg1 uint64) + func (m *MockChain) SetDelegateeReward(arg0 ids.ID, arg1 ids.NodeID, arg2 uint64) error + func (m *MockChain) SetSubnetOwner(arg0 ids.ID, arg1 fx.Owner) + func (m *MockChain) SetTimestamp(arg0 time.Time) + type MockChainMockRecorder struct + func (mr *MockChainMockRecorder) AddChain(arg0 any) *gomock.Call + func (mr *MockChainMockRecorder) AddRewardUTXO(arg0, arg1 any) *gomock.Call + func (mr *MockChainMockRecorder) AddSubnet(arg0 any) *gomock.Call + func (mr *MockChainMockRecorder) AddSubnetTransformation(arg0 any) *gomock.Call + func (mr *MockChainMockRecorder) AddTx(arg0, arg1 any) *gomock.Call + func (mr *MockChainMockRecorder) AddUTXO(arg0 any) *gomock.Call + func (mr *MockChainMockRecorder) DeleteCurrentDelegator(arg0 any) *gomock.Call + func (mr *MockChainMockRecorder) DeleteCurrentValidator(arg0 any) *gomock.Call + func (mr *MockChainMockRecorder) DeletePendingDelegator(arg0 any) *gomock.Call + func (mr *MockChainMockRecorder) DeletePendingValidator(arg0 any) *gomock.Call + func (mr *MockChainMockRecorder) DeleteUTXO(arg0 any) *gomock.Call + func (mr *MockChainMockRecorder) GetCurrentDelegatorIterator(arg0, arg1 any) *gomock.Call + func (mr *MockChainMockRecorder) GetCurrentStakerIterator() *gomock.Call + func (mr *MockChainMockRecorder) GetCurrentSupply(arg0 any) *gomock.Call + func (mr *MockChainMockRecorder) GetCurrentValidator(arg0, arg1 any) *gomock.Call + func (mr *MockChainMockRecorder) GetDelegateeReward(arg0, arg1 any) *gomock.Call + func (mr *MockChainMockRecorder) GetPendingDelegatorIterator(arg0, arg1 any) *gomock.Call + func (mr *MockChainMockRecorder) GetPendingStakerIterator() *gomock.Call + func (mr *MockChainMockRecorder) GetPendingValidator(arg0, arg1 any) *gomock.Call + func (mr *MockChainMockRecorder) GetSubnetOwner(arg0 any) *gomock.Call + func (mr *MockChainMockRecorder) GetSubnetTransformation(arg0 any) *gomock.Call + func (mr *MockChainMockRecorder) GetTimestamp() *gomock.Call + func (mr *MockChainMockRecorder) GetTx(arg0 any) *gomock.Call + func (mr *MockChainMockRecorder) GetUTXO(arg0 any) *gomock.Call + func (mr *MockChainMockRecorder) PutCurrentDelegator(arg0 any) *gomock.Call + func (mr *MockChainMockRecorder) PutCurrentValidator(arg0 any) *gomock.Call + func (mr *MockChainMockRecorder) PutPendingDelegator(arg0 any) *gomock.Call + func (mr *MockChainMockRecorder) PutPendingValidator(arg0 any) *gomock.Call + func (mr *MockChainMockRecorder) SetCurrentSupply(arg0, arg1 any) *gomock.Call + func (mr *MockChainMockRecorder) SetDelegateeReward(arg0, arg1, arg2 any) *gomock.Call + func (mr *MockChainMockRecorder) SetSubnetOwner(arg0, arg1 any) *gomock.Call + func (mr *MockChainMockRecorder) SetTimestamp(arg0 any) *gomock.Call + type MockDiff struct + func NewMockDiff(ctrl *gomock.Controller) *MockDiff + func (m *MockDiff) AddChain(arg0 *txs.Tx) + func (m *MockDiff) AddRewardUTXO(arg0 ids.ID, arg1 *lux.UTXO) + func (m *MockDiff) AddSubnet(arg0 ids.ID) + func (m *MockDiff) AddSubnetTransformation(arg0 *txs.Tx) + func (m *MockDiff) AddTx(arg0 *txs.Tx, arg1 status.Status) + func (m *MockDiff) AddUTXO(arg0 *lux.UTXO) + func (m *MockDiff) Apply(arg0 Chain) error + func (m *MockDiff) DeleteCurrentDelegator(arg0 *Staker) + func (m *MockDiff) DeleteCurrentValidator(arg0 *Staker) + func (m *MockDiff) DeletePendingDelegator(arg0 *Staker) + func (m *MockDiff) DeletePendingValidator(arg0 *Staker) + func (m *MockDiff) DeleteUTXO(arg0 ids.ID) + func (m *MockDiff) EXPECT() *MockDiffMockRecorder + func (m *MockDiff) GetCurrentDelegatorIterator(arg0 ids.ID, arg1 ids.NodeID) (StakerIterator, error) + func (m *MockDiff) GetCurrentStakerIterator() (StakerIterator, error) + func (m *MockDiff) GetCurrentSupply(arg0 ids.ID) (uint64, error) + func (m *MockDiff) GetCurrentValidator(arg0 ids.ID, arg1 ids.NodeID) (*Staker, error) + func (m *MockDiff) GetDelegateeReward(arg0 ids.ID, arg1 ids.NodeID) (uint64, error) + func (m *MockDiff) GetPendingDelegatorIterator(arg0 ids.ID, arg1 ids.NodeID) (StakerIterator, error) + func (m *MockDiff) GetPendingStakerIterator() (StakerIterator, error) + func (m *MockDiff) GetPendingValidator(arg0 ids.ID, arg1 ids.NodeID) (*Staker, error) + func (m *MockDiff) GetSubnetOwner(arg0 ids.ID) (fx.Owner, error) + func (m *MockDiff) GetSubnetTransformation(arg0 ids.ID) (*txs.Tx, error) + func (m *MockDiff) GetTimestamp() time.Time + func (m *MockDiff) GetTx(arg0 ids.ID) (*txs.Tx, status.Status, error) + func (m *MockDiff) GetUTXO(arg0 ids.ID) (*lux.UTXO, error) + func (m *MockDiff) PutCurrentDelegator(arg0 *Staker) + func (m *MockDiff) PutCurrentValidator(arg0 *Staker) + func (m *MockDiff) PutPendingDelegator(arg0 *Staker) + func (m *MockDiff) PutPendingValidator(arg0 *Staker) + func (m *MockDiff) SetCurrentSupply(arg0 ids.ID, arg1 uint64) + func (m *MockDiff) SetDelegateeReward(arg0 ids.ID, arg1 ids.NodeID, arg2 uint64) error + func (m *MockDiff) SetSubnetOwner(arg0 ids.ID, arg1 fx.Owner) + func (m *MockDiff) SetTimestamp(arg0 time.Time) + type MockDiffMockRecorder struct + func (mr *MockDiffMockRecorder) AddChain(arg0 any) *gomock.Call + func (mr *MockDiffMockRecorder) AddRewardUTXO(arg0, arg1 any) *gomock.Call + func (mr *MockDiffMockRecorder) AddSubnet(arg0 any) *gomock.Call + func (mr *MockDiffMockRecorder) AddSubnetTransformation(arg0 any) *gomock.Call + func (mr *MockDiffMockRecorder) AddTx(arg0, arg1 any) *gomock.Call + func (mr *MockDiffMockRecorder) AddUTXO(arg0 any) *gomock.Call + func (mr *MockDiffMockRecorder) Apply(arg0 any) *gomock.Call + func (mr *MockDiffMockRecorder) DeleteCurrentDelegator(arg0 any) *gomock.Call + func (mr *MockDiffMockRecorder) DeleteCurrentValidator(arg0 any) *gomock.Call + func (mr *MockDiffMockRecorder) DeletePendingDelegator(arg0 any) *gomock.Call + func (mr *MockDiffMockRecorder) DeletePendingValidator(arg0 any) *gomock.Call + func (mr *MockDiffMockRecorder) DeleteUTXO(arg0 any) *gomock.Call + func (mr *MockDiffMockRecorder) GetCurrentDelegatorIterator(arg0, arg1 any) *gomock.Call + func (mr *MockDiffMockRecorder) GetCurrentStakerIterator() *gomock.Call + func (mr *MockDiffMockRecorder) GetCurrentSupply(arg0 any) *gomock.Call + func (mr *MockDiffMockRecorder) GetCurrentValidator(arg0, arg1 any) *gomock.Call + func (mr *MockDiffMockRecorder) GetDelegateeReward(arg0, arg1 any) *gomock.Call + func (mr *MockDiffMockRecorder) GetPendingDelegatorIterator(arg0, arg1 any) *gomock.Call + func (mr *MockDiffMockRecorder) GetPendingStakerIterator() *gomock.Call + func (mr *MockDiffMockRecorder) GetPendingValidator(arg0, arg1 any) *gomock.Call + func (mr *MockDiffMockRecorder) GetSubnetOwner(arg0 any) *gomock.Call + func (mr *MockDiffMockRecorder) GetSubnetTransformation(arg0 any) *gomock.Call + func (mr *MockDiffMockRecorder) GetTimestamp() *gomock.Call + func (mr *MockDiffMockRecorder) GetTx(arg0 any) *gomock.Call + func (mr *MockDiffMockRecorder) GetUTXO(arg0 any) *gomock.Call + func (mr *MockDiffMockRecorder) PutCurrentDelegator(arg0 any) *gomock.Call + func (mr *MockDiffMockRecorder) PutCurrentValidator(arg0 any) *gomock.Call + func (mr *MockDiffMockRecorder) PutPendingDelegator(arg0 any) *gomock.Call + func (mr *MockDiffMockRecorder) PutPendingValidator(arg0 any) *gomock.Call + func (mr *MockDiffMockRecorder) SetCurrentSupply(arg0, arg1 any) *gomock.Call + func (mr *MockDiffMockRecorder) SetDelegateeReward(arg0, arg1, arg2 any) *gomock.Call + func (mr *MockDiffMockRecorder) SetSubnetOwner(arg0, arg1 any) *gomock.Call + func (mr *MockDiffMockRecorder) SetTimestamp(arg0 any) *gomock.Call + type MockStakerIterator struct + func NewMockStakerIterator(ctrl *gomock.Controller) *MockStakerIterator + func (m *MockStakerIterator) EXPECT() *MockStakerIteratorMockRecorder + func (m *MockStakerIterator) Next() bool + func (m *MockStakerIterator) Release() + func (m *MockStakerIterator) Value() *Staker + type MockStakerIteratorMockRecorder struct + func (mr *MockStakerIteratorMockRecorder) Next() *gomock.Call + func (mr *MockStakerIteratorMockRecorder) Release() *gomock.Call + func (mr *MockStakerIteratorMockRecorder) Value() *gomock.Call + type MockState struct + func NewMockState(ctrl *gomock.Controller) *MockState + func (m *MockState) Abort() + func (m *MockState) AddChain(arg0 *txs.Tx) + func (m *MockState) AddRewardUTXO(arg0 ids.ID, arg1 *lux.UTXO) + func (m *MockState) AddStatelessBlock(arg0 block.Block) + func (m *MockState) AddSubnet(arg0 ids.ID) + func (m *MockState) AddSubnetTransformation(arg0 *txs.Tx) + func (m *MockState) AddTx(arg0 *txs.Tx, arg1 status.Status) + func (m *MockState) AddUTXO(arg0 *lux.UTXO) + func (m *MockState) ApplyValidatorPublicKeyDiffs(arg0 context.Context, arg1 map[ids.NodeID]*validators.GetValidatorOutput, ...) error + func (m *MockState) ApplyValidatorWeightDiffs(arg0 context.Context, arg1 map[ids.NodeID]*validators.GetValidatorOutput, ...) error + func (m *MockState) Checksum() ids.ID + func (m *MockState) Close() error + func (m *MockState) Commit() error + func (m *MockState) CommitBatch() (database.Batch, error) + func (m *MockState) DeleteCurrentDelegator(arg0 *Staker) + func (m *MockState) DeleteCurrentValidator(arg0 *Staker) + func (m *MockState) DeletePendingDelegator(arg0 *Staker) + func (m *MockState) DeletePendingValidator(arg0 *Staker) + func (m *MockState) DeleteUTXO(arg0 ids.ID) + func (m *MockState) EXPECT() *MockStateMockRecorder + func (m *MockState) GetBlockIDAtHeight(arg0 uint64) (ids.ID, error) + func (m *MockState) GetChains(arg0 ids.ID) ([]*txs.Tx, error) + func (m *MockState) GetCurrentDelegatorIterator(arg0 ids.ID, arg1 ids.NodeID) (StakerIterator, error) + func (m *MockState) GetCurrentStakerIterator() (StakerIterator, error) + func (m *MockState) GetCurrentSupply(arg0 ids.ID) (uint64, error) + func (m *MockState) GetCurrentValidator(arg0 ids.ID, arg1 ids.NodeID) (*Staker, error) + func (m *MockState) GetDelegateeReward(arg0 ids.ID, arg1 ids.NodeID) (uint64, error) + func (m *MockState) GetLastAccepted() ids.ID + func (m *MockState) GetPendingDelegatorIterator(arg0 ids.ID, arg1 ids.NodeID) (StakerIterator, error) + func (m *MockState) GetPendingStakerIterator() (StakerIterator, error) + func (m *MockState) GetPendingValidator(arg0 ids.ID, arg1 ids.NodeID) (*Staker, error) + func (m *MockState) GetRewardUTXOs(arg0 ids.ID) ([]*lux.UTXO, error) + func (m *MockState) GetStartTime(arg0 ids.NodeID, arg1 ids.ID) (time.Time, error) + func (m *MockState) GetStatelessBlock(arg0 ids.ID) (block.Block, error) + func (m *MockState) GetSubnetIDs() ([]ids.ID, error) + func (m *MockState) GetSubnetOwner(arg0 ids.ID) (fx.Owner, error) + func (m *MockState) GetSubnetTransformation(arg0 ids.ID) (*txs.Tx, error) + func (m *MockState) GetTimestamp() time.Time + func (m *MockState) GetTx(arg0 ids.ID) (*txs.Tx, status.Status, error) + func (m *MockState) GetUTXO(arg0 ids.ID) (*lux.UTXO, error) + func (m *MockState) GetUptime(arg0 ids.NodeID, arg1 ids.ID) (time.Duration, time.Time, error) + func (m *MockState) PutCurrentDelegator(arg0 *Staker) + func (m *MockState) PutCurrentValidator(arg0 *Staker) + func (m *MockState) PutPendingDelegator(arg0 *Staker) + func (m *MockState) PutPendingValidator(arg0 *Staker) + func (m *MockState) ReindexBlocks(arg0 sync.Locker, arg1 logging.Logger) error + func (m *MockState) SetCurrentSupply(arg0 ids.ID, arg1 uint64) + func (m *MockState) SetDelegateeReward(arg0 ids.ID, arg1 ids.NodeID, arg2 uint64) error + func (m *MockState) SetHeight(arg0 uint64) + func (m *MockState) SetLastAccepted(arg0 ids.ID) + func (m *MockState) SetSubnetOwner(arg0 ids.ID, arg1 fx.Owner) + func (m *MockState) SetTimestamp(arg0 time.Time) + func (m *MockState) SetUptime(arg0 ids.NodeID, arg1 ids.ID, arg2 time.Duration, arg3 time.Time) error + func (m *MockState) UTXOIDs(arg0 []byte, arg1 ids.ID, arg2 int) ([]ids.ID, error) + type MockStateMockRecorder struct + func (mr *MockStateMockRecorder) Abort() *gomock.Call + func (mr *MockStateMockRecorder) AddChain(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) AddRewardUTXO(arg0, arg1 any) *gomock.Call + func (mr *MockStateMockRecorder) AddStatelessBlock(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) AddSubnet(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) AddSubnetTransformation(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) AddTx(arg0, arg1 any) *gomock.Call + func (mr *MockStateMockRecorder) AddUTXO(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) ApplyValidatorPublicKeyDiffs(arg0, arg1, arg2, arg3 any) *gomock.Call + func (mr *MockStateMockRecorder) ApplyValidatorWeightDiffs(arg0, arg1, arg2, arg3, arg4 any) *gomock.Call + func (mr *MockStateMockRecorder) Checksum() *gomock.Call + func (mr *MockStateMockRecorder) Close() *gomock.Call + func (mr *MockStateMockRecorder) Commit() *gomock.Call + func (mr *MockStateMockRecorder) CommitBatch() *gomock.Call + func (mr *MockStateMockRecorder) DeleteCurrentDelegator(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) DeleteCurrentValidator(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) DeletePendingDelegator(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) DeletePendingValidator(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) DeleteUTXO(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) GetBlockIDAtHeight(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) GetChains(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) GetCurrentDelegatorIterator(arg0, arg1 any) *gomock.Call + func (mr *MockStateMockRecorder) GetCurrentStakerIterator() *gomock.Call + func (mr *MockStateMockRecorder) GetCurrentSupply(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) GetCurrentValidator(arg0, arg1 any) *gomock.Call + func (mr *MockStateMockRecorder) GetDelegateeReward(arg0, arg1 any) *gomock.Call + func (mr *MockStateMockRecorder) GetLastAccepted() *gomock.Call + func (mr *MockStateMockRecorder) GetPendingDelegatorIterator(arg0, arg1 any) *gomock.Call + func (mr *MockStateMockRecorder) GetPendingStakerIterator() *gomock.Call + func (mr *MockStateMockRecorder) GetPendingValidator(arg0, arg1 any) *gomock.Call + func (mr *MockStateMockRecorder) GetRewardUTXOs(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) GetStartTime(arg0, arg1 any) *gomock.Call + func (mr *MockStateMockRecorder) GetStatelessBlock(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) GetSubnetIDs() *gomock.Call + func (mr *MockStateMockRecorder) GetSubnetOwner(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) GetSubnetTransformation(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) GetTimestamp() *gomock.Call + func (mr *MockStateMockRecorder) GetTx(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) GetUTXO(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) GetUptime(arg0, arg1 any) *gomock.Call + func (mr *MockStateMockRecorder) PutCurrentDelegator(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) PutCurrentValidator(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) PutPendingDelegator(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) PutPendingValidator(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) ReindexBlocks(arg0, arg1 any) *gomock.Call + func (mr *MockStateMockRecorder) SetCurrentSupply(arg0, arg1 any) *gomock.Call + func (mr *MockStateMockRecorder) SetDelegateeReward(arg0, arg1, arg2 any) *gomock.Call + func (mr *MockStateMockRecorder) SetHeight(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) SetLastAccepted(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) SetSubnetOwner(arg0, arg1 any) *gomock.Call + func (mr *MockStateMockRecorder) SetTimestamp(arg0 any) *gomock.Call + func (mr *MockStateMockRecorder) SetUptime(arg0, arg1, arg2, arg3 any) *gomock.Call + func (mr *MockStateMockRecorder) UTXOIDs(arg0, arg1, arg2 any) *gomock.Call + type MockVersions struct + func NewMockVersions(ctrl *gomock.Controller) *MockVersions + func (m *MockVersions) EXPECT() *MockVersionsMockRecorder + func (m *MockVersions) GetState(arg0 ids.ID) (Chain, bool) + type MockVersionsMockRecorder struct + func (mr *MockVersionsMockRecorder) GetState(arg0 any) *gomock.Call + type PendingStakers interface + DeletePendingDelegator func(staker *Staker) + DeletePendingValidator func(staker *Staker) + GetPendingDelegatorIterator func(subnetID ids.ID, nodeID ids.NodeID) (StakerIterator, error) + GetPendingStakerIterator func() (StakerIterator, error) + GetPendingValidator func(subnetID ids.ID, nodeID ids.NodeID) (*Staker, error) + PutPendingDelegator func(staker *Staker) + PutPendingValidator func(staker *Staker) + type Staker struct + EndTime time.Time + NextTime time.Time + NodeID ids.NodeID + PotentialReward uint64 + Priority txs.Priority + PublicKey *bls.PublicKey + StartTime time.Time + SubnetID ids.ID + TxID ids.ID + Weight uint64 + func NewCurrentStaker(txID ids.ID, staker txs.Staker, startTime time.Time, potentialReward uint64) (*Staker, error) + func NewPendingStaker(txID ids.ID, staker txs.ScheduledStaker) (*Staker, error) + func (s *Staker) Less(than *Staker) bool + type StakerDiffIterator interface + Next func() bool + Release func() + Value func() (*Staker, bool) + func NewStakerDiffIterator(currentIterator, pendingIterator StakerIterator) StakerDiffIterator + type StakerIterator interface + Next func() bool + Release func() + Value func() *Staker + var EmptyIterator StakerIterator = emptyIterator{} + func NewMaskedIterator(parentIterator StakerIterator, maskedStakers map[ids.ID]*Staker) StakerIterator + func NewMergedIterator(stakers ...StakerIterator) StakerIterator + func NewTreeIterator(tree *btree.BTreeG[*Staker]) StakerIterator + type Stakers interface + type State interface + Abort func() + AddStatelessBlock func(block block.Block) + ApplyValidatorPublicKeyDiffs func(ctx context.Context, validators map[ids.NodeID]*validators.GetValidatorOutput, ...) error + ApplyValidatorWeightDiffs func(ctx context.Context, validators map[ids.NodeID]*validators.GetValidatorOutput, ...) error + Checksum func() ids.ID + Close func() error + Commit func() error + CommitBatch func() (database.Batch, error) + GetBlockIDAtHeight func(height uint64) (ids.ID, error) + GetChains func(subnetID ids.ID) ([]*txs.Tx, error) + GetLastAccepted func() ids.ID + GetRewardUTXOs func(txID ids.ID) ([]*lux.UTXO, error) + GetStatelessBlock func(blockID ids.ID) (block.Block, error) + GetSubnetIDs func() ([]ids.ID, error) + ReindexBlocks func(lock sync.Locker, log logging.Logger) error + SetHeight func(height uint64) + SetLastAccepted func(blkID ids.ID) + func New(db database.Database, genesisBytes []byte, metricsReg prometheus.Registerer, ...) (State, error) + type ValidatorWeightDiff struct + Amount uint64 + Decrease bool + func (v *ValidatorWeightDiff) Add(negative bool, amount uint64) error + type Versions interface + GetState func(blkID ids.ID) (Chain, bool)