package
0.5.5
Repository: https://github.com/elitak/go-libp2p-core.git
Documentation: pkg.go.dev

# Functions

GetDialPeerTimeout returns the current DialPeer timeout (or the default).
GetNoDial returns true if the no dial option is set in the context.
WithDialPeerTimeout returns a new context with the DialPeer timeout applied.
WithNoDial constructs a new context with an option that instructs the network to not attempt a new dial when opening a stream.

# Constants

CanConnect means recently connected to peer, terminated gracefully.
CannotConnect means recently attempted connecting but failed to connect.
Connected means has an open, live connection to peer.
DirInbound is for when the remote peer initiated a connection.
DirOutbound is for when the local peer initiated a connection.
DirUnknown is the default direction.
4 MB.
NotConnected means no connection to peer, and no extra information (default).
ReachabilityPrivate indicates that the node is not reachable from the public internet.
ReachabilityPublic indicates that the node is reachable from the public internet.
ReachabilityUnknown indicates that the reachability status of the node is unknown.

# Variables

DialPeerTimeout is the default timeout for a single call to `DialPeer`.
ErrNoConn is returned when attempting to open a stream to a peer with the NoDial option and no usable connection is available.
ErrNoRemoteAddrs is returned when there are no addresses associated with a peer during a dial.
Global noop notifiee.

# Structs

No description provided by the author
NotifyBundle implements Notifiee by calling any of the functions set on it, and nop'ing if they are unset.
Stat stores metadata pertaining to a given Stream/Conn.

# Interfaces

Conn is a connection to a remote peer.
ConnMultiaddrs is an interface mixin for connection types that provide multiaddr addresses for the endpoints.
ConnSecurity is the interface that one can mix into a connection interface to give it the security methods.
Dialer represents a service that can dial out to peers (this is usually just a Network, but other services may not need the whole stack, and thus it becomes easier to mock).
Network is the interface used to connect to the outside world.
Notifiee is an interface for an object wishing to receive notifications from a Network.
Stream represents a bidirectional channel between two agents in a libp2p network.

# Type aliases

Connectedness signals the capacity for a connection with a given node.
ConnHandler is the type of function used to listen for connections opened by the remote side.
Direction represents which peer in a stream initiated a connection.
Reachability indicates how reachable a node is.
StreamHandler is the type of function used to listen for streams opened by the remote side.