Documentation
¶
Overview ¶
Package validatorsmock is a generated GoMock package.
Package validatorsmock is a generated GoMock package.
Package validatorsmock is a generated GoMock package.
Index ¶
- type Manager
- func (m *Manager) Add(subnetID ids.ID, arg1 validators.Set) error
- func (m *Manager) Contains(subnetID ids.ID) bool
- func (m *Manager) Count() int
- func (m *Manager) EXPECT() *ManagerMockRecorder
- func (m *Manager) Get(subnetID ids.ID) (validators.Set, bool)
- func (m *Manager) GetByWeight(subnetID ids.ID, minWeight uint64) (validators.Set, bool)
- func (m *Manager) GetValidator(subnetID ids.ID, nodeID ids.NodeID) (*validators.Validator, error)
- func (m *Manager) GetWeight(subnetID ids.ID, nodeID ids.NodeID) uint64
- func (m *Manager) RecalculateStakes(subnetID ids.ID) error
- func (m *Manager) Remove(subnetID ids.ID) error
- func (m *Manager) String() string
- func (m *Manager) TotalWeight(subnetID ids.ID) (uint64, error)
- type ManagerMockRecorder
- func (mr *ManagerMockRecorder) Add(subnetID, arg1 any) *gomock.Call
- func (mr *ManagerMockRecorder) Contains(subnetID any) *gomock.Call
- func (mr *ManagerMockRecorder) Count() *gomock.Call
- func (mr *ManagerMockRecorder) Get(subnetID any) *gomock.Call
- func (mr *ManagerMockRecorder) GetByWeight(subnetID, minWeight any) *gomock.Call
- func (mr *ManagerMockRecorder) GetValidator(subnetID, nodeID any) *gomock.Call
- func (mr *ManagerMockRecorder) GetWeight(subnetID, nodeID any) *gomock.Call
- func (mr *ManagerMockRecorder) RecalculateStakes(subnetID any) *gomock.Call
- func (mr *ManagerMockRecorder) Remove(subnetID any) *gomock.Call
- func (mr *ManagerMockRecorder) String() *gomock.Call
- func (mr *ManagerMockRecorder) TotalWeight(subnetID any) *gomock.Call
- type Set
- func (m *Set) Add(nodeID ids.NodeID, pk []byte, weight uint64) error
- func (m *Set) AddWeight(nodeID ids.NodeID, weight uint64) error
- func (m *Set) Contains(nodeID ids.NodeID) bool
- func (m *Set) EXPECT() *SetMockRecorder
- func (m *Set) Get(nodeID ids.NodeID) (*validators.Validator, bool)
- func (m *Set) Len() int
- func (m *Set) List() []*validators.Validator
- func (m *Set) Remove(nodeID ids.NodeID) error
- func (m *Set) RemoveWeight(nodeID ids.NodeID, weight uint64) error
- func (m *Set) Sample(seed uint64) (ids.NodeID, error)
- func (m *Set) String() string
- func (m *Set) Weight() uint64
- type SetMockRecorder
- func (mr *SetMockRecorder) Add(nodeID, pk, weight any) *gomock.Call
- func (mr *SetMockRecorder) AddWeight(nodeID, weight any) *gomock.Call
- func (mr *SetMockRecorder) Contains(nodeID any) *gomock.Call
- func (mr *SetMockRecorder) Get(nodeID any) *gomock.Call
- func (mr *SetMockRecorder) Len() *gomock.Call
- func (mr *SetMockRecorder) List() *gomock.Call
- func (mr *SetMockRecorder) Remove(nodeID any) *gomock.Call
- func (mr *SetMockRecorder) RemoveWeight(nodeID, weight any) *gomock.Call
- func (mr *SetMockRecorder) Sample(seed any) *gomock.Call
- func (mr *SetMockRecorder) String() *gomock.Call
- func (mr *SetMockRecorder) Weight() *gomock.Call
- type State
- func (m *State) EXPECT() *StateMockRecorder
- func (m *State) GetCurrentHeight(ctx context.Context) (uint64, error)
- func (m *State) GetMinimumHeight(ctx context.Context) (uint64, error)
- func (m *State) GetSubnetID(ctx context.Context, chainID ids.ID) (ids.ID, error)
- func (m *State) GetValidatorSet(ctx context.Context, height uint64, subnetID ids.ID) (map[ids.NodeID]*validators.GetValidatorOutput, error)
- type StateMockRecorder
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
Manager is a mock of Manager interface.
func NewManager ¶
func NewManager(ctrl *gomock.Controller) *Manager
NewManager creates a new mock instance.
func (*Manager) EXPECT ¶
func (m *Manager) EXPECT() *ManagerMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*Manager) GetByWeight ¶
GetByWeight mocks base method.
func (*Manager) GetValidator ¶
GetValidator mocks base method.
func (*Manager) RecalculateStakes ¶
RecalculateStakes mocks base method.
type ManagerMockRecorder ¶
type ManagerMockRecorder struct {
// contains filtered or unexported fields
}
ManagerMockRecorder is the mock recorder for Manager.
func (*ManagerMockRecorder) Add ¶
func (mr *ManagerMockRecorder) Add(subnetID, arg1 any) *gomock.Call
Add indicates an expected call of Add.
func (*ManagerMockRecorder) Contains ¶
func (mr *ManagerMockRecorder) Contains(subnetID any) *gomock.Call
Contains indicates an expected call of Contains.
func (*ManagerMockRecorder) Count ¶
func (mr *ManagerMockRecorder) Count() *gomock.Call
Count indicates an expected call of Count.
func (*ManagerMockRecorder) Get ¶
func (mr *ManagerMockRecorder) Get(subnetID any) *gomock.Call
Get indicates an expected call of Get.
func (*ManagerMockRecorder) GetByWeight ¶
func (mr *ManagerMockRecorder) GetByWeight(subnetID, minWeight any) *gomock.Call
GetByWeight indicates an expected call of GetByWeight.
func (*ManagerMockRecorder) GetValidator ¶
func (mr *ManagerMockRecorder) GetValidator(subnetID, nodeID any) *gomock.Call
GetValidator indicates an expected call of GetValidator.
func (*ManagerMockRecorder) GetWeight ¶
func (mr *ManagerMockRecorder) GetWeight(subnetID, nodeID any) *gomock.Call
GetWeight indicates an expected call of GetWeight.
func (*ManagerMockRecorder) RecalculateStakes ¶
func (mr *ManagerMockRecorder) RecalculateStakes(subnetID any) *gomock.Call
RecalculateStakes indicates an expected call of RecalculateStakes.
func (*ManagerMockRecorder) Remove ¶
func (mr *ManagerMockRecorder) Remove(subnetID any) *gomock.Call
Remove indicates an expected call of Remove.
func (*ManagerMockRecorder) String ¶
func (mr *ManagerMockRecorder) String() *gomock.Call
String indicates an expected call of String.
func (*ManagerMockRecorder) TotalWeight ¶
func (mr *ManagerMockRecorder) TotalWeight(subnetID any) *gomock.Call
TotalWeight indicates an expected call of TotalWeight.
type Set ¶
type Set struct {
// contains filtered or unexported fields
}
Set is a mock of Set interface.
func (*Set) EXPECT ¶
func (m *Set) EXPECT() *SetMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*Set) RemoveWeight ¶
RemoveWeight mocks base method.
type SetMockRecorder ¶
type SetMockRecorder struct {
// contains filtered or unexported fields
}
SetMockRecorder is the mock recorder for Set.
func (*SetMockRecorder) Add ¶
func (mr *SetMockRecorder) Add(nodeID, pk, weight any) *gomock.Call
Add indicates an expected call of Add.
func (*SetMockRecorder) AddWeight ¶
func (mr *SetMockRecorder) AddWeight(nodeID, weight any) *gomock.Call
AddWeight indicates an expected call of AddWeight.
func (*SetMockRecorder) Contains ¶
func (mr *SetMockRecorder) Contains(nodeID any) *gomock.Call
Contains indicates an expected call of Contains.
func (*SetMockRecorder) Get ¶
func (mr *SetMockRecorder) Get(nodeID any) *gomock.Call
Get indicates an expected call of Get.
func (*SetMockRecorder) Len ¶
func (mr *SetMockRecorder) Len() *gomock.Call
Len indicates an expected call of Len.
func (*SetMockRecorder) List ¶
func (mr *SetMockRecorder) List() *gomock.Call
List indicates an expected call of List.
func (*SetMockRecorder) Remove ¶
func (mr *SetMockRecorder) Remove(nodeID any) *gomock.Call
Remove indicates an expected call of Remove.
func (*SetMockRecorder) RemoveWeight ¶
func (mr *SetMockRecorder) RemoveWeight(nodeID, weight any) *gomock.Call
RemoveWeight indicates an expected call of RemoveWeight.
func (*SetMockRecorder) Sample ¶
func (mr *SetMockRecorder) Sample(seed any) *gomock.Call
Sample indicates an expected call of Sample.
func (*SetMockRecorder) String ¶
func (mr *SetMockRecorder) String() *gomock.Call
String indicates an expected call of String.
func (*SetMockRecorder) Weight ¶
func (mr *SetMockRecorder) Weight() *gomock.Call
Weight indicates an expected call of Weight.
type State ¶
type State struct {
// contains filtered or unexported fields
}
State is a mock of State interface.
func (*State) EXPECT ¶
func (m *State) EXPECT() *StateMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*State) GetCurrentHeight ¶
GetCurrentHeight mocks base method.
func (*State) GetMinimumHeight ¶
GetMinimumHeight mocks base method.
func (*State) GetSubnetID ¶
GetSubnetID mocks base method.
func (*State) GetValidatorSet ¶
func (m *State) GetValidatorSet(ctx context.Context, height uint64, subnetID ids.ID) (map[ids.NodeID]*validators.GetValidatorOutput, error)
GetValidatorSet mocks base method.
type StateMockRecorder ¶
type StateMockRecorder struct {
// contains filtered or unexported fields
}
StateMockRecorder is the mock recorder for State.
func (*StateMockRecorder) GetCurrentHeight ¶
func (mr *StateMockRecorder) GetCurrentHeight(ctx any) *gomock.Call
GetCurrentHeight indicates an expected call of GetCurrentHeight.
func (*StateMockRecorder) GetMinimumHeight ¶
func (mr *StateMockRecorder) GetMinimumHeight(ctx any) *gomock.Call
GetMinimumHeight indicates an expected call of GetMinimumHeight.
func (*StateMockRecorder) GetSubnetID ¶
func (mr *StateMockRecorder) GetSubnetID(ctx, chainID any) *gomock.Call
GetSubnetID indicates an expected call of GetSubnetID.
func (*StateMockRecorder) GetValidatorSet ¶
func (mr *StateMockRecorder) GetValidatorSet(ctx, height, subnetID any) *gomock.Call
GetValidatorSet indicates an expected call of GetValidatorSet.