Versions in this module Expand all Collapse all v0 v0.0.1 Mar 20, 2024 Changes in this version + func NewNetworkShardingCollectorMock() *networkShardingCollectorMock + func NewPrivateKeyMock() *privateKeyMock + func NewStreamMock() *streamMock + type CacherStub struct + ClearCalled func() + CloseCalled func() error + GetCalled func(key []byte) (value interface{}, ok bool) + HasCalled func(key []byte) bool + HasOrAddCalled func(key []byte, value interface{}, sizeInBytes int) (has, added bool) + KeysCalled func() [][]byte + LenCalled func() int + MaxSizeCalled func() int + PeekCalled func(key []byte) (value interface{}, ok bool) + PutCalled func(key []byte, value interface{}, sizeInBytes int) (evicted bool) + RegisterHandlerCalled func(func(key []byte, value interface{})) + RemoveCalled func(key []byte) + RemoveOldestCalled func() + UnRegisterHandlerCalled func(id string) + func (cacher *CacherStub) Clear() + func (cacher *CacherStub) Close() error + func (cacher *CacherStub) Get(key []byte) (value interface{}, ok bool) + func (cacher *CacherStub) Has(key []byte) bool + func (cacher *CacherStub) HasOrAdd(key []byte, value interface{}, sizeInBytes int) (has, added bool) + func (cacher *CacherStub) IsInterfaceNil() bool + func (cacher *CacherStub) Keys() [][]byte + func (cacher *CacherStub) Len() int + func (cacher *CacherStub) MaxSize() int + func (cacher *CacherStub) Peek(key []byte) (value interface{}, ok bool) + func (cacher *CacherStub) Put(key []byte, value interface{}, sizeInBytes int) (evicted bool) + func (cacher *CacherStub) RegisterHandler(handler func(key []byte, value interface{}), _ string) + func (cacher *CacherStub) Remove(key []byte) + func (cacher *CacherStub) SizeInBytesContained() uint64 + func (cacher *CacherStub) UnRegisterHandler(id string) + type ChannelLoadBalancerStub struct + AddChannelCalled func(pipe string) error + CloseCalled func() error + CollectOneElementFromChannelsCalled func() *libp2p.SendableData + GetChannelOrDefaultCalled func(pipe string) chan *libp2p.SendableData + RemoveChannelCalled func(pipe string) error + func (clbs *ChannelLoadBalancerStub) AddChannel(pipe string) error + func (clbs *ChannelLoadBalancerStub) Close() error + func (clbs *ChannelLoadBalancerStub) CollectOneElementFromChannels() *libp2p.SendableData + func (clbs *ChannelLoadBalancerStub) GetChannelOrDefault(pipe string) chan *libp2p.SendableData + func (clbs *ChannelLoadBalancerStub) IsInterfaceNil() bool + func (clbs *ChannelLoadBalancerStub) RemoveChannel(pipe string) error + type ConnStub struct + CloseCalled func() error + ConnStateCalled func() network.ConnectionState + GetStreamsCalled func() []network.Stream + IDCalled func() string + IsClosedCalled func() bool + LocalMultiaddrCalled func() multiaddr.Multiaddr + LocalPeerCalled func() peer.ID + LocalPrivateKeyCalled func() libp2pCrypto.PrivKey + NewStreamCalled func(ctx context.Context) (network.Stream, error) + RemoteMultiaddrCalled func() multiaddr.Multiaddr + RemotePeerCalled func() peer.ID + RemotePublicKeyCalled func() libp2pCrypto.PubKey + ScopeCalled func() network.ConnScope + StatCalled func() network.ConnStats + func (cs *ConnStub) Close() error + func (cs *ConnStub) ConnState() network.ConnectionState + func (cs *ConnStub) GetStreams() []network.Stream + func (cs *ConnStub) ID() string + func (cs *ConnStub) IsClosed() bool + func (cs *ConnStub) LocalMultiaddr() multiaddr.Multiaddr + func (cs *ConnStub) LocalPeer() peer.ID + func (cs *ConnStub) LocalPrivateKey() libp2pCrypto.PrivKey + func (cs *ConnStub) NewStream(ctx context.Context) (network.Stream, error) + func (cs *ConnStub) RemoteMultiaddr() multiaddr.Multiaddr + func (cs *ConnStub) RemotePeer() peer.ID + func (cs *ConnStub) RemotePublicKey() libp2pCrypto.PubKey + func (cs *ConnStub) Scope() network.ConnScope + func (cs *ConnStub) Stat() network.ConnStats + type ConnectableHostStub struct + AddressToPeerInfoCalled func(address string) (*peer.AddrInfo, error) + AddrsCalled func() []multiaddr.Multiaddr + CloseCalled func() error + ConnManagerCalled func() connmgr.ConnManager + ConnectCalled func(ctx context.Context, pi peer.AddrInfo) error + ConnectToPeerCalled func(ctx context.Context, address string) error + EventBusCalled func() event.Bus + IDCalled func() peer.ID + MuxCalled func() protocol.Switch + NetworkCalled func() network.Network + NewStreamCalled func(ctx context.Context, p peer.ID, pids ...protocol.ID) (network.Stream, error) + PeerstoreCalled func() peerstore.Peerstore + RemoveStreamHandlerCalled func(pid protocol.ID) + SetStreamHandlerCalled func(pid protocol.ID, handler network.StreamHandler) + SetStreamHandlerMatchCalled func(id protocol.ID, f func(protocol.ID) bool, handler network.StreamHandler) + func (hs *ConnectableHostStub) AddressToPeerInfo(address string) (*peer.AddrInfo, error) + func (hs *ConnectableHostStub) Addrs() []multiaddr.Multiaddr + func (hs *ConnectableHostStub) Close() error + func (hs *ConnectableHostStub) ConnManager() connmgr.ConnManager + func (hs *ConnectableHostStub) Connect(ctx context.Context, pi peer.AddrInfo) error + func (hs *ConnectableHostStub) ConnectToPeer(ctx context.Context, address string) error + func (hs *ConnectableHostStub) EventBus() event.Bus + func (hs *ConnectableHostStub) ID() peer.ID + func (hs *ConnectableHostStub) IsInterfaceNil() bool + func (hs *ConnectableHostStub) Mux() protocol.Switch + func (hs *ConnectableHostStub) Network() network.Network + func (hs *ConnectableHostStub) NewStream(ctx context.Context, p peer.ID, pids ...protocol.ID) (network.Stream, error) + func (hs *ConnectableHostStub) Peerstore() peerstore.Peerstore + func (hs *ConnectableHostStub) RemoveStreamHandler(pid protocol.ID) + func (hs *ConnectableHostStub) SetStreamHandler(pid protocol.ID, handler network.StreamHandler) + func (hs *ConnectableHostStub) SetStreamHandlerMatch(id protocol.ID, f func(protocol.ID) bool, handler network.StreamHandler) + type ConnectionMonitorStub struct + CloseCalled func() error + ConnectedCalled func(netw network.Network, conn network.Conn) + DisconnectedCalled func(netw network.Network, conn network.Conn) + IsConnectedToTheNetworkCalled func(netw network.Network) bool + ListenCalled func(netw network.Network, ma multiaddr.Multiaddr) + ListenCloseCalled func(netw network.Network, ma multiaddr.Multiaddr) + PeerDenialEvaluatorCalled func() p2p.PeerDenialEvaluator + SetPeerDenialEvaluatorCalled func(handler p2p.PeerDenialEvaluator) error + SetThresholdMinConnectedPeersCalled func(thresholdMinConnectedPeers int, netw network.Network) + ThresholdMinConnectedPeersCalled func() int + func (cms *ConnectionMonitorStub) Close() error + func (cms *ConnectionMonitorStub) Connected(netw network.Network, conn network.Conn) + func (cms *ConnectionMonitorStub) Disconnected(netw network.Network, conn network.Conn) + func (cms *ConnectionMonitorStub) IsConnectedToTheNetwork(netw network.Network) bool + func (cms *ConnectionMonitorStub) IsInterfaceNil() bool + func (cms *ConnectionMonitorStub) Listen(netw network.Network, ma multiaddr.Multiaddr) + func (cms *ConnectionMonitorStub) ListenClose(netw network.Network, ma multiaddr.Multiaddr) + func (cms *ConnectionMonitorStub) PeerDenialEvaluator() p2p.PeerDenialEvaluator + func (cms *ConnectionMonitorStub) SetPeerDenialEvaluator(handler p2p.PeerDenialEvaluator) error + func (cms *ConnectionMonitorStub) SetThresholdMinConnectedPeers(thresholdMinConnectedPeers int, netw network.Network) + func (cms *ConnectionMonitorStub) ThresholdMinConnectedPeers() int + type ConnectionsMetricStub struct + ConnectedCalled func(core.Network, core.Conn) + DisconnectedCalled func(core.Network, core.Conn) + ListenCalled func(core.Network, core.Multiaddr) + ListenCloseCalled func(core.Network, core.Multiaddr) + ResetNumConnectionsCalled func() uint32 + ResetNumDisconnectionsCalled func() uint32 + func (stub *ConnectionsMetricStub) Connected(network core.Network, conn core.Conn) + func (stub *ConnectionsMetricStub) Disconnected(network core.Network, conn core.Conn) + func (stub *ConnectionsMetricStub) IsInterfaceNil() bool + func (stub *ConnectionsMetricStub) Listen(network core.Network, addr core.Multiaddr) + func (stub *ConnectionsMetricStub) ListenClose(network core.Network, addr core.Multiaddr) + func (stub *ConnectionsMetricStub) ResetNumConnections() uint32 + func (stub *ConnectionsMetricStub) ResetNumDisconnections() uint32 + type ConnectionsWatcherStub struct + CloseCalled func() error + NewKnownConnectionCalled func(pid core.PeerID, connection string) + func (stub *ConnectionsWatcherStub) Close() error + func (stub *ConnectionsWatcherStub) IsInterfaceNil() bool + func (stub *ConnectionsWatcherStub) NewKnownConnection(pid core.PeerID, connection string) + type DebuggerStub struct + AddIncomingMessageCalled func(topic string, size uint64, isRejected bool) + AddOutgoingMessageCalled func(topic string, size uint64, isRejected bool) + CloseCalled func() error + func (stub *DebuggerStub) AddIncomingMessage(topic string, size uint64, isRejected bool) + func (stub *DebuggerStub) AddOutgoingMessage(topic string, size uint64, isRejected bool) + func (stub *DebuggerStub) Close() error + func (stub *DebuggerStub) IsInterfaceNil() bool + type DirectSenderStub struct + NextSequenceNumberCalled func() []byte + RegisterDirectMessageProcessorCalled func(handler p2p.MessageHandler) error + SendCalled func(topic string, buff []byte, peer core.PeerID) error + func (stub *DirectSenderStub) IsInterfaceNil() bool + func (stub *DirectSenderStub) NextSequenceNumber() []byte + func (stub *DirectSenderStub) RegisterDirectMessageProcessor(handler p2p.MessageHandler) error + func (stub *DirectSenderStub) Send(topic string, buff []byte, peer core.PeerID) error + type EventBusStub struct + EmitterCalled func(eventType interface{}, opts ...event.EmitterOpt) (event.Emitter, error) + GetAllEventTypesCalled func() []reflect.Type + SubscribeCalled func(eventType interface{}, opts ...event.SubscriptionOpt) (event.Subscription, error) + func (ebs *EventBusStub) Emitter(eventType interface{}, opts ...event.EmitterOpt) (event.Emitter, error) + func (ebs *EventBusStub) GetAllEventTypes() []reflect.Type + func (ebs *EventBusStub) Subscribe(eventType interface{}, opts ...event.SubscriptionOpt) (event.Subscription, error) + type EventSubscriptionStub struct + CloseCalled func() error + NameCalled func() string + OutCalled func() <-chan interface{} + func (ess *EventSubscriptionStub) Close() error + func (ess *EventSubscriptionStub) Name() string + func (ess *EventSubscriptionStub) Out() <-chan interface{} + type KadDhtHandlerStub struct + BootstrapCalled func(ctx context.Context) error + func (kdhs *KadDhtHandlerStub) Bootstrap(ctx context.Context) error + type KadSharderStub struct + ComputeEvictListCalled func(pidList []peer.ID) []peer.ID + HasCalled func(pid peer.ID, list []peer.ID) bool + IsSeederCalled func(pid core.PeerID) bool + SetPeerShardResolverCalled func(psp p2p.PeerShardResolver) error + SetSeedersCalled func(addresses []string) + func (kss *KadSharderStub) ComputeEvictionList(pidList []peer.ID) []peer.ID + func (kss *KadSharderStub) Has(pid peer.ID, list []peer.ID) bool + func (kss *KadSharderStub) IsInterfaceNil() bool + func (kss *KadSharderStub) IsSeeder(pid core.PeerID) bool + func (kss *KadSharderStub) SetPeerShardResolver(psp p2p.PeerShardResolver) error + func (kss *KadSharderStub) SetSeeders(addresses []string) + type KeyGenStub struct + CheckPublicKeyValidStub func(b []byte) error + GeneratePairStub func() (crypto.PrivateKey, crypto.PublicKey) + PrivateKeyFromByteArrayStub func(b []byte) (crypto.PrivateKey, error) + PublicKeyFromByteArrayStub func(b []byte) (crypto.PublicKey, error) + SuiteStub func() crypto.Suite + func (keyGen *KeyGenStub) CheckPublicKeyValid(b []byte) error + func (keyGen *KeyGenStub) GeneratePair() (crypto.PrivateKey, crypto.PublicKey) + func (keyGen *KeyGenStub) IsInterfaceNil() bool + func (keyGen *KeyGenStub) PrivateKeyFromByteArray(b []byte) (crypto.PrivateKey, error) + func (keyGen *KeyGenStub) PublicKeyFromByteArray(b []byte) (crypto.PublicKey, error) + func (keyGen *KeyGenStub) Suite() crypto.Suite + type MessageHandlerStub struct + BroadcastCalled func(topic string, buff []byte) + BroadcastOnChannelCalled func(channel string, topic string, buff []byte) + BroadcastOnChannelUsingPrivateKeyCalled func(channel string, topic string, buff []byte, pid core.PeerID, skBytes []byte) + BroadcastUsingPrivateKeyCalled func(topic string, buff []byte, pid core.PeerID, skBytes []byte) + CloseCalled func() error + CreateTopicCalled func(name string, createChannelForTopic bool) error + HasTopicCalled func(name string) bool + ProcessReceivedMessageCalled func(message p2p.MessageP2P, fromConnectedPeer core.PeerID, ...) error + RegisterMessageProcessorCalled func(topic string, identifier string, handler p2p.MessageProcessor) error + SendToConnectedPeerCalled func(topic string, buff []byte, peerID core.PeerID) error + UnJoinAllTopicsCalled func() error + UnregisterAllMessageProcessorsCalled func() error + UnregisterMessageProcessorCalled func(topic string, identifier string) error + func (stub *MessageHandlerStub) Broadcast(topic string, buff []byte) + func (stub *MessageHandlerStub) BroadcastOnChannel(channel string, topic string, buff []byte) + func (stub *MessageHandlerStub) BroadcastOnChannelUsingPrivateKey(channel string, topic string, buff []byte, pid core.PeerID, skBytes []byte) + func (stub *MessageHandlerStub) BroadcastUsingPrivateKey(topic string, buff []byte, pid core.PeerID, skBytes []byte) + func (stub *MessageHandlerStub) Close() error + func (stub *MessageHandlerStub) CreateTopic(name string, createChannelForTopic bool) error + func (stub *MessageHandlerStub) HasTopic(name string) bool + func (stub *MessageHandlerStub) IsInterfaceNil() bool + func (stub *MessageHandlerStub) ProcessReceivedMessage(message p2p.MessageP2P, fromConnectedPeer core.PeerID, ...) error + func (stub *MessageHandlerStub) RegisterMessageProcessor(topic string, identifier string, handler p2p.MessageProcessor) error + func (stub *MessageHandlerStub) SendToConnectedPeer(topic string, buff []byte, peerID core.PeerID) error + func (stub *MessageHandlerStub) UnJoinAllTopics() error + func (stub *MessageHandlerStub) UnregisterAllMessageProcessors() error + func (stub *MessageHandlerStub) UnregisterMessageProcessor(topic string, identifier string) error + type MessageProcessorMock struct + func NewMessageProcessorMock() *MessageProcessorMock + func (processor *MessageProcessorMock) GetMessages() map[core.PeerID]int + func (processor *MessageProcessorMock) IsInterfaceNil() bool + func (processor *MessageProcessorMock) ProcessReceivedMessage(message p2p.MessageP2P, _ core.PeerID, _ p2p.MessageHandler) error + type MessageProcessorStub struct + ProcessMessageCalled func(message p2p.MessageP2P, fromConnectedPeer core.PeerID, ...) error + func (mps *MessageProcessorStub) IsInterfaceNil() bool + func (mps *MessageProcessorStub) ProcessReceivedMessage(message p2p.MessageP2P, fromConnectedPeer core.PeerID, ...) error + type MultiaddrStub struct + BytesCalled func() []byte + DecapsulateCalled func(multiaddr multiaddr.Multiaddr) multiaddr.Multiaddr + EncapsulateCalled func(multiaddr multiaddr.Multiaddr) multiaddr.Multiaddr + EqualCalled func(multiaddr multiaddr.Multiaddr) bool + MarshalBinaryCalled func() (data []byte, err error) + MarshalJSONCalled func() ([]byte, error) + MarshalTextCalled func() (text []byte, err error) + ProtocolsCalled func() []multiaddr.Protocol + StringCalled func() string + UnmarshalBinaryCalled func(data []byte) error + UnmarshalJSONCalled func(bytes []byte) error + UnmarshalTextCalled func(text []byte) error + ValueForProtocolCalled func(code int) (string, error) + func (mas *MultiaddrStub) Bytes() []byte + func (mas *MultiaddrStub) Decapsulate(multiaddr multiaddr.Multiaddr) multiaddr.Multiaddr + func (mas *MultiaddrStub) Encapsulate(multiaddr multiaddr.Multiaddr) multiaddr.Multiaddr + func (mas *MultiaddrStub) Equal(multiaddr multiaddr.Multiaddr) bool + func (mas *MultiaddrStub) MarshalBinary() (data []byte, err error) + func (mas *MultiaddrStub) MarshalJSON() ([]byte, error) + func (mas *MultiaddrStub) MarshalText() (text []byte, err error) + func (mas *MultiaddrStub) Protocols() []multiaddr.Protocol + func (mas *MultiaddrStub) String() string + func (mas *MultiaddrStub) UnmarshalBinary(data []byte) error + func (mas *MultiaddrStub) UnmarshalJSON(bytes []byte) error + func (mas *MultiaddrStub) UnmarshalText(text []byte) error + func (mas *MultiaddrStub) ValueForProtocol(code int) (string, error) + type NetworkStub struct + ClosePeerCall func(peer.ID) error + ConnectednessCalled func(peer.ID) network.Connectedness + ConnsCalled func() []network.Conn + ConnsToPeerCalled func(p peer.ID) []network.Conn + NotifyCalled func(network.Notifiee) + PeersCall func() []peer.ID + ResourceManagerCalled func() network.ResourceManager + StopNotifyCalled func(network.Notifiee) + func (ns *NetworkStub) Close() error + func (ns *NetworkStub) ClosePeer(pid peer.ID) error + func (ns *NetworkStub) Connectedness(pid peer.ID) network.Connectedness + func (ns *NetworkStub) Conns() []network.Conn + func (ns *NetworkStub) ConnsToPeer(p peer.ID) []network.Conn + func (ns *NetworkStub) DialPeer(_ context.Context, _ peer.ID) (network.Conn, error) + func (ns *NetworkStub) InterfaceListenAddresses() ([]multiaddr.Multiaddr, error) + func (ns *NetworkStub) Listen(...multiaddr.Multiaddr) error + func (ns *NetworkStub) ListenAddresses() []multiaddr.Multiaddr + func (ns *NetworkStub) LocalPeer() peer.ID + func (ns *NetworkStub) NewStream(context.Context, peer.ID) (network.Stream, error) + func (ns *NetworkStub) Notify(notifee network.Notifiee) + func (ns *NetworkStub) Peers() []peer.ID + func (ns *NetworkStub) Peerstore() peerstore.Peerstore + func (ns *NetworkStub) Process() goprocess.Process + func (ns *NetworkStub) ResourceManager() network.ResourceManager + func (ns *NetworkStub) SetStreamHandler(network.StreamHandler) + func (ns *NetworkStub) StopNotify(notifee network.Notifiee) + type P2PSignerStub struct + SignCalled func(payload []byte) ([]byte, error) + SignUsingPrivateKeyCalled func(skBytes []byte, payload []byte) ([]byte, error) + VerifyCalled func(payload []byte, pid core.PeerID, signature []byte) error + func (stub *P2PSignerStub) IsInterfaceNil() bool + func (stub *P2PSignerStub) Sign(payload []byte) ([]byte, error) + func (stub *P2PSignerStub) SignUsingPrivateKey(skBytes []byte, payload []byte) ([]byte, error) + func (stub *P2PSignerStub) Verify(payload []byte, pid core.PeerID, signature []byte) error + type PeerDenialEvaluatorStub struct + IsDeniedCalled func(pid core.PeerID) bool + UpsertPeerIDCalled func(pid core.PeerID, duration time.Duration) error + func (pdes *PeerDenialEvaluatorStub) IsDenied(pid core.PeerID) bool + func (pdes *PeerDenialEvaluatorStub) IsInterfaceNil() bool + func (pdes *PeerDenialEvaluatorStub) UpsertPeerID(pid core.PeerID, duration time.Duration) error + type PeerDiscovererStub struct + BootstrapCalled func() error + CloseCalled func() error + func (pds *PeerDiscovererStub) Bootstrap() error + func (pds *PeerDiscovererStub) IsInterfaceNil() bool + func (pds *PeerDiscovererStub) Name() string + type PeerShardResolverStub struct + GetPeerInfoCalled func(pid core.PeerID) core.P2PPeerInfo + func (psrs *PeerShardResolverStub) GetPeerInfo(pid core.PeerID) core.P2PPeerInfo + func (psrs *PeerShardResolverStub) IsInterfaceNil() bool + type PeerTopicNotifierStub struct + NewPeerFoundCalled func(pid core.PeerID, topic string) + func (stub *PeerTopicNotifierStub) IsInterfaceNil() bool + func (stub *PeerTopicNotifierStub) NewPeerFound(pid core.PeerID, topic string) + type PeersHolderStub struct + ClearCalled func() + ContainsCalled func(peerID core.PeerID) bool + GetCalled func() map[uint32][]core.PeerID + PutConnectionAddressCalled func(peerID core.PeerID, address string) + PutShardIDCalled func(peerID core.PeerID, shardID uint32) + RemoveCalled func(peerID core.PeerID) + func (p *PeersHolderStub) Clear() + func (p *PeersHolderStub) Contains(peerID core.PeerID) bool + func (p *PeersHolderStub) Get() map[uint32][]core.PeerID + func (p *PeersHolderStub) IsInterfaceNil() bool + func (p *PeersHolderStub) PutConnectionAddress(peerID core.PeerID, address string) + func (p *PeersHolderStub) PutShardID(peerID core.PeerID, shardID uint32) + func (p *PeersHolderStub) Remove(peerID core.PeerID) + type PeersOnChannelStub struct + CloseCalled func() error + ConnectedPeersOnChannelCalled func(topic string) []core.PeerID + func (stub *PeersOnChannelStub) Close() error + func (stub *PeersOnChannelStub) ConnectedPeersOnChannel(topic string) []core.PeerID + func (stub *PeersOnChannelStub) IsInterfaceNil() bool + type PeersRatingHandlerStub struct + DecreaseRatingCalled func(pid core.PeerID) + GetTopRatedPeersFromListCalled func(peers []core.PeerID, numOfPeers int) []core.PeerID + IncreaseRatingCalled func(pid core.PeerID) + func (stub *PeersRatingHandlerStub) DecreaseRating(pid core.PeerID) + func (stub *PeersRatingHandlerStub) GetTopRatedPeersFromList(peers []core.PeerID, numOfPeers int) []core.PeerID + func (stub *PeersRatingHandlerStub) IncreaseRating(pid core.PeerID) + func (stub *PeersRatingHandlerStub) IsInterfaceNil() bool + type PeerstoreStub struct + AddAddrCalled func(p peer.ID, addr multiaddr.Multiaddr, ttl time.Duration) + AddAddrsCalled func(p peer.ID, addrs []multiaddr.Multiaddr, ttl time.Duration) + AddPrivKeyCalled func(id peer.ID, key libp2pCrypto.PrivKey) error + AddProtocolsCalled func(id peer.ID, id2 ...protocol.ID) error + AddPubKeyCalled func(id peer.ID, key libp2pCrypto.PubKey) error + AddrStreamCalled func(ctx context.Context, id peer.ID) <-chan multiaddr.Multiaddr + AddrsCalled func(p peer.ID) []multiaddr.Multiaddr + ClearAddrsCalled func(p peer.ID) + CloseCalled func() error + FirstSupportedProtocolCalled func(id peer.ID, id2 ...protocol.ID) (protocol.ID, error) + GetCalled func(p peer.ID, key string) (interface{}, error) + GetProtocolsCalled func(id peer.ID) ([]protocol.ID, error) + LatencyEWMACalled func(id peer.ID) time.Duration + PeerInfoCalled func(id peer.ID) peer.AddrInfo + PeersCalled func() peer.IDSlice + PeersWithAddrsCalled func() peer.IDSlice + PeersWithKeysCalled func() peer.IDSlice + PrivKeyCalled func(id peer.ID) libp2pCrypto.PrivKey + PubKeyCalled func(id peer.ID) libp2pCrypto.PubKey + PutCalled func(p peer.ID, key string, val interface{}) error + RecordLatencyCalled func(id peer.ID, duration time.Duration) + RemovePeerCalled func(id peer.ID) + RemoveProtocolsCalled func(id peer.ID, id2 ...protocol.ID) error + SetAddrCalled func(p peer.ID, addr multiaddr.Multiaddr, ttl time.Duration) + SetAddrsCalled func(p peer.ID, addrs []multiaddr.Multiaddr, ttl time.Duration) + SetProtocolsCalled func(id peer.ID, id2 ...protocol.ID) error + SupportsProtocolsCalled func(id peer.ID, id2 ...protocol.ID) ([]protocol.ID, error) + UpdateAddrsCalled func(p peer.ID, oldTTL time.Duration, newTTL time.Duration) + func (ps *PeerstoreStub) AddAddr(p peer.ID, addr multiaddr.Multiaddr, ttl time.Duration) + func (ps *PeerstoreStub) AddAddrs(p peer.ID, addrs []multiaddr.Multiaddr, ttl time.Duration) + func (ps *PeerstoreStub) AddPrivKey(id peer.ID, key libp2pCrypto.PrivKey) error + func (ps *PeerstoreStub) AddProtocols(id peer.ID, id2 ...protocol.ID) error + func (ps *PeerstoreStub) AddPubKey(id peer.ID, key libp2pCrypto.PubKey) error + func (ps *PeerstoreStub) AddrStream(ctx context.Context, id peer.ID) <-chan multiaddr.Multiaddr + func (ps *PeerstoreStub) Addrs(p peer.ID) []multiaddr.Multiaddr + func (ps *PeerstoreStub) ClearAddrs(p peer.ID) + func (ps *PeerstoreStub) Close() error + func (ps *PeerstoreStub) FirstSupportedProtocol(id peer.ID, id2 ...protocol.ID) (protocol.ID, error) + func (ps *PeerstoreStub) Get(p peer.ID, key string) (interface{}, error) + func (ps *PeerstoreStub) GetProtocols(id peer.ID) ([]protocol.ID, error) + func (ps *PeerstoreStub) LatencyEWMA(id peer.ID) time.Duration + func (ps *PeerstoreStub) PeerInfo(id peer.ID) peer.AddrInfo + func (ps *PeerstoreStub) Peers() peer.IDSlice + func (ps *PeerstoreStub) PeersWithAddrs() peer.IDSlice + func (ps *PeerstoreStub) PeersWithKeys() peer.IDSlice + func (ps *PeerstoreStub) PrivKey(id peer.ID) libp2pCrypto.PrivKey + func (ps *PeerstoreStub) PubKey(id peer.ID) libp2pCrypto.PubKey + func (ps *PeerstoreStub) Put(p peer.ID, key string, val interface{}) error + func (ps *PeerstoreStub) RecordLatency(id peer.ID, duration time.Duration) + func (ps *PeerstoreStub) RemovePeer(id peer.ID) + func (ps *PeerstoreStub) RemoveProtocols(id peer.ID, id2 ...protocol.ID) error + func (ps *PeerstoreStub) SetAddr(p peer.ID, addr multiaddr.Multiaddr, ttl time.Duration) + func (ps *PeerstoreStub) SetAddrs(p peer.ID, addrs []multiaddr.Multiaddr, ttl time.Duration) + func (ps *PeerstoreStub) SetProtocols(id peer.ID, id2 ...protocol.ID) error + func (ps *PeerstoreStub) SupportsProtocols(id peer.ID, id2 ...protocol.ID) ([]protocol.ID, error) + func (ps *PeerstoreStub) UpdateAddrs(p peer.ID, oldTTL time.Duration, newTTL time.Duration) + type PrivateKeyStub struct + GeneratePublicStub func() crypto.PublicKey + ScalarStub func() crypto.Scalar + SuiteStub func() crypto.Suite + ToByteArrayStub func() ([]byte, error) + func (privKey *PrivateKeyStub) GeneratePublic() crypto.PublicKey + func (privKey *PrivateKeyStub) IsInterfaceNil() bool + func (privKey *PrivateKeyStub) Scalar() crypto.Scalar + func (privKey *PrivateKeyStub) Suite() crypto.Suite + func (privKey *PrivateKeyStub) ToByteArray() ([]byte, error) + type PubSubStub struct + GetTopicsCalled func() []string + JoinCalled func(topic string, opts ...pubsub.TopicOpt) (*pubsub.Topic, error) + ListPeersCalled func(topic string) []peer.ID + RegisterTopicValidatorCalled func(topic string, val interface{}, opts ...pubsub.ValidatorOpt) error + UnregisterTopicValidatorCalled func(topic string) error + func (stub *PubSubStub) GetTopics() []string + func (stub *PubSubStub) Join(topic string, opts ...pubsub.TopicOpt) (*pubsub.Topic, error) + func (stub *PubSubStub) ListPeers(topic string) []peer.ID + func (stub *PubSubStub) RegisterTopicValidator(topic string, val interface{}, opts ...pubsub.ValidatorOpt) error + func (stub *PubSubStub) UnregisterTopicValidator(topic string) error + type PubSubSubscriptionStub struct + CancelCalled func() + NextCalled func(ctx context.Context) (*pubsub.Message, error) + TopicCalled func() string + func (stub *PubSubSubscriptionStub) Cancel() + func (stub *PubSubSubscriptionStub) Next(ctx context.Context) (*pubsub.Message, error) + func (stub *PubSubSubscriptionStub) Topic() string + type PubSubTopicStub struct + CloseCalled func() error + PublishCalled func(ctx context.Context, data []byte, opts ...pubsub.PubOpt) error + SubscribeCalled func(opts ...pubsub.SubOpt) (*pubsub.Subscription, error) + func (stub *PubSubTopicStub) Close() error + func (stub *PubSubTopicStub) Publish(ctx context.Context, data []byte, opts ...pubsub.PubOpt) error + func (stub *PubSubTopicStub) Subscribe(opts ...pubsub.SubOpt) (*pubsub.Subscription, error) + type PublicKeyStub struct + PointStub func() crypto.Point + SuiteStub func() crypto.Suite + ToByteArrayStub func() ([]byte, error) + func (pubKey *PublicKeyStub) IsInterfaceNil() bool + func (pubKey *PublicKeyStub) Point() crypto.Point + func (pubKey *PublicKeyStub) Suite() crypto.Suite + func (pubKey *PublicKeyStub) ToByteArray() ([]byte, error) + type ReconnecterStub struct + PauseCall func() + ReconnectToNetworkCalled func(ctx context.Context) + ResumeCall func() + func (rs *ReconnecterStub) IsInterfaceNil() bool + func (rs *ReconnecterStub) ReconnectToNetwork(ctx context.Context) + type SharderStub struct + IsSeederCalled func(pid core.PeerID) bool + SetPeerShardResolverCalled func(psp p2p.PeerShardResolver) error + SetSeedersCalled func(addresses []string) + func (ss *SharderStub) IsInterfaceNil() bool + func (ss *SharderStub) IsSeeder(pid core.PeerID) bool + func (ss *SharderStub) SetPeerShardResolver(psp p2p.PeerShardResolver) error + func (ss *SharderStub) SetSeeders(addresses []string) + type SingleSignerStub struct + SignCalled func(private crypto.PrivateKey, msg []byte) ([]byte, error) + VerifyCalled func(public crypto.PublicKey, msg []byte, sig []byte) error + func (s *SingleSignerStub) IsInterfaceNil() bool + func (s *SingleSignerStub) Sign(private crypto.PrivateKey, msg []byte) ([]byte, error) + func (s *SingleSignerStub) Verify(public crypto.PublicKey, msg []byte, sig []byte) error + type SyncTimerStub struct + CurrentTimeCalled func() time.Time + func (sts *SyncTimerStub) CurrentTime() time.Time + func (sts *SyncTimerStub) IsInterfaceNil() bool + type ThrottlerStub struct + CanProcessCalled func() bool + EndProcessingCalled func() + StartProcessingCalled func() + func (stub *ThrottlerStub) CanProcess() bool + func (stub *ThrottlerStub) EndProcessing() + func (stub *ThrottlerStub) IsInterfaceNil() bool + func (stub *ThrottlerStub) StartProcessing() + type TopicProcessorStub struct + AddTopicProcessorCalled func(identifier string, processor p2p.MessageProcessor) error + GetListCalled func() ([]string, []p2p.MessageProcessor) + RemoveTopicProcessorCalled func(identifier string) error + func (stub *TopicProcessorStub) AddTopicProcessor(identifier string, processor p2p.MessageProcessor) error + func (stub *TopicProcessorStub) GetList() ([]string, []p2p.MessageProcessor) + func (stub *TopicProcessorStub) IsInterfaceNil() bool + func (stub *TopicProcessorStub) RemoveTopicProcessor(identifier string) error