Versions in this module Expand all Collapse all v1 v1.999.0 Nov 17, 2022 Changes in this version + const DirectSendID + const ListenAddrWithIp4AndTcp + const ListenLocalhostAddrWithIp4AndTcp + func NewConnectableHost(h host.Host) *connectableHost + func NewDirectSender(ctx context.Context, h host.Host, ...) (*directSender, error) + func NewMessage(msg *pubsub.Message, marshalizer p2p.Marshalizer) (*message.Message, error) + func NewMockMessenger(args ArgsNetworkMessenger, mockNet mocknet.Mocknet) (*networkMessenger, error) + func NewNetworkMessenger(args ArgsNetworkMessenger) (*networkMessenger, error) + type ArgsNetworkMessenger struct + ConnectionWatcherType string + ListenAddress string + Marshalizer p2p.Marshalizer + NodeOperationMode p2p.NodeOperation + P2pConfig config.P2PConfig + PeersRatingHandler p2p.PeersRatingHandler + PreferredPeersHolder p2p.PreferredPeersHolderHandler + SyncTimer p2p.SyncTimer + type ConnectableHost interface + AddressToPeerInfo func(address string) (*peer.AddrInfo, error) + ConnectToPeer func(ctx context.Context, address string) error + IsInterfaceNil func() bool + type ConnectionMonitor interface + Close func() error + IsConnectedToTheNetwork func(netw network.Network) bool + IsInterfaceNil func() bool + SetThresholdMinConnectedPeers func(thresholdMinConnectedPeers int, netw network.Network) + ThresholdMinConnectedPeers func() int + type LocalSyncTimer struct + func (lst *LocalSyncTimer) CurrentTime() time.Time + func (lst *LocalSyncTimer) IsInterfaceNil() bool + type MutexHolder struct + func NewMutexHolder(mutexesCapacity int) (*MutexHolder, error) + func (mh *MutexHolder) Get(key string) *sync.Mutex + type PeerDiscovererWithSharder interface + SetSharder func(sharder p2p.Sharder) error + type PeerInfoHandler func(pInfo peer.AddrInfo)