Versions in this module Expand all Collapse all v1 v1.0.0 Jun 19, 2022 Changes in this version + type Connector interface + Connected func(id ids.ShortID, nodeVersion version.Application) error + Disconnected func(id ids.ShortID) error + type Manager interface + AddWeight func(ids.ID, ids.ShortID, uint64) error + Contains func(ids.ID, ids.ShortID) bool + GetValidators func(ids.ID) (Set, bool) + MaskValidator func(ids.ShortID) error + RemoveWeight func(ids.ID, ids.ShortID, uint64) error + RevealValidator func(ids.ShortID) error + Set func(ids.ID, Set) error + func NewManager() Manager + type Set interface + AddWeight func(ids.ShortID, uint64) error + Contains func(ids.ShortID) bool + GetWeight func(ids.ShortID) (uint64, bool) + Len func() int + List func() []Validator + MaskValidator func(ids.ShortID) error + PrefixedString func(string) string + RemoveWeight func(ids.ShortID, uint64) error + RevealValidator func(ids.ShortID) error + Sample func(size int) ([]Validator, error) + Set func([]Validator) error + SubsetWeight func(ids.ShortSet) (uint64, error) + Weight func() uint64 + func NewBestSet(expectedSampleSize int) Set + func NewSet() Set + type State interface + GetCurrentHeight func() (uint64, error) + GetValidatorSet func(height uint64, subnetID ids.ID) (map[ids.ShortID]uint64, error) + func NewLockedState(lock sync.Locker, s State) State + func NewNoState() State + type TestState struct + CantGetCurrentHeight bool + CantGetValidatorSet bool + GetCurrentHeightF func() (uint64, error) + GetValidatorSetF func(height uint64, subnetID ids.ID) (map[ids.ShortID]uint64, error) + T *testing.T + func (vm *TestState) GetCurrentHeight() (uint64, error) + func (vm *TestState) GetValidatorSet(height uint64, subnetID ids.ID) (map[ids.ShortID]uint64, error) + type Validator interface + ID func() ids.ShortID + Weight func() uint64 + func GenerateRandomValidator(weight uint64) Validator + func NewValidator(nodeID ids.ShortID, weight uint64) Validator