Versions in this module Expand all Collapse all v1 v1.999.0 Nov 17, 2022 Changes in this version + func NewMultipleShardsCoordinatorFake(numOfShards uint32, currentShard uint32) *multipleShardsCoordinatorFake + type EpochHandlerMock struct + EpochValue uint32 + func (ehm *EpochHandlerMock) Epoch() uint32 + func (ehm *EpochHandlerMock) IsInterfaceNil() bool + type EpochHandlerStub struct + EpochCalled func() uint32 + func (ehs *EpochHandlerStub) Epoch() uint32 + func (ehs *EpochHandlerStub) IsInterfaceNil() bool + type EpochStartNotifierStub struct + NotifyAllCalled func(hdr data.HeaderHandler) + NotifyAllPrepareCalled func(hdr data.HeaderHandler, body data.BodyHandler) + RegisterHandlerCalled func(handler epochStart.ActionHandler) + UnregisterHandlerCalled func(handler epochStart.ActionHandler) + func (esnm *EpochStartNotifierStub) IsInterfaceNil() bool + func (esnm *EpochStartNotifierStub) NotifyAll(hdr data.HeaderHandler) + func (esnm *EpochStartNotifierStub) NotifyAllPrepare(metaHdr data.HeaderHandler, body data.BodyHandler) + func (esnm *EpochStartNotifierStub) RegisterHandler(handler epochStart.ActionHandler) + func (esnm *EpochStartNotifierStub) UnregisterHandler(handler epochStart.ActionHandler) + type HasherStub struct + ComputeCalled func(s string) []byte + EmptyHashCalled func() []byte + SizeCalled func() int + func (hs *HasherStub) Compute(s string) []byte + func (hs *HasherStub) EmptyHash() []byte + func (hs *HasherStub) IsInterfaceNil() bool + func (hs *HasherStub) Size() int + type ListIndexUpdaterStub struct + UpdateListAndIndexCalled func(pubKey string, shardID uint32, list string, index uint32) error + func (lius *ListIndexUpdaterStub) IsInterfaceNil() bool + func (lius *ListIndexUpdaterStub) UpdateListAndIndex(pubKey string, shardID uint32, list string, index uint32) error + type MarshalizerMock struct + Fail bool + func (mm *MarshalizerMock) IsInterfaceNil() bool + func (mm *MarshalizerMock) Marshal(obj interface{}) ([]byte, error) + func (mm *MarshalizerMock) Unmarshal(obj interface{}, buff []byte) error + type NodesCoordinatorCacheMock struct + ClearCalled func() + GetCalled func(key []byte) (value interface{}, ok bool) + PutCalled func(key []byte, value interface{}, sieInBytes int) (evicted bool) + func (rm *NodesCoordinatorCacheMock) Clear() + func (rm *NodesCoordinatorCacheMock) Get(key []byte) (value interface{}, ok bool) + func (rm *NodesCoordinatorCacheMock) Put(key []byte, value interface{}, sizeInBytes int) (evicted bool) + type PubkeyConverterMock struct + func NewPubkeyConverterMock(addressLen int) *PubkeyConverterMock + func (pcm *PubkeyConverterMock) Decode(humanReadable string) ([]byte, error) + func (pcm *PubkeyConverterMock) Encode(pkBytes []byte) string + func (pcm *PubkeyConverterMock) IsInterfaceNil() bool + func (pcm *PubkeyConverterMock) Len() int + type RaterMock struct + ComputeRatingCalled func(string, uint32) uint32 + GetChancesCalled func(uint32) uint32 + GetRatingCalled func(string) uint32 + GetStartRatingCalled func() uint32 + func (rm *RaterMock) ComputeRating(ratingOptionKey string, previousValue uint32) uint32 + func (rm *RaterMock) GetChance(rating uint32) uint32 + func (rm *RaterMock) GetRating(pk string) uint32 + func (rm *RaterMock) GetStartRating() uint32 + func (rm *RaterMock) IsInterfaceNil() bool + type ShuffledOutHandlerStub struct + CurrentShardIDCalled func() uint32 + ProcessCalled func(newShardID uint32) error + RegisterHandlerCalled func(handler func(newShardID uint32)) + func (s *ShuffledOutHandlerStub) CurrentShardID() uint32 + func (s *ShuffledOutHandlerStub) IsInterfaceNil() bool + func (s *ShuffledOutHandlerStub) Process(newShardID uint32) error + func (s *ShuffledOutHandlerStub) RegisterHandler(handler func(newShardID uint32))