Documentation ¶
Index ¶
- type ConnectionNotifee
- func (cn *ConnectionNotifee) ClosedStream(netw network.Network, stream network.Stream)
- func (n *ConnectionNotifee) Connected(netw network.Network, conn network.Conn)
- func (cn *ConnectionNotifee) Disconnected(netw network.Network, conn network.Conn)
- func (n *ConnectionNotifee) Listen(netw network.Network, ma multiaddr.Multiaddr)
- func (n *ConnectionNotifee) ListenClose(netw network.Network, ma multiaddr.Multiaddr)
- func (cn *ConnectionNotifee) OpenedStream(netw network.Network, stream network.Stream)
- type DiscoveryNotifee
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConnectionNotifee ¶
func (*ConnectionNotifee) ClosedStream ¶
func (cn *ConnectionNotifee) ClosedStream(netw network.Network, stream network.Stream)
ClosedStream is called when a stream was closed
func (*ConnectionNotifee) Connected ¶
func (n *ConnectionNotifee) Connected(netw network.Network, conn network.Conn)
Connected is called when a connection opened
func (*ConnectionNotifee) Disconnected ¶
func (cn *ConnectionNotifee) Disconnected(netw network.Network, conn network.Conn)
Disconnected is called when a connection closed
func (*ConnectionNotifee) Listen ¶
func (n *ConnectionNotifee) Listen(netw network.Network, ma multiaddr.Multiaddr)
Listen is called when network starts listening on an addr
func (*ConnectionNotifee) ListenClose ¶
func (n *ConnectionNotifee) ListenClose(netw network.Network, ma multiaddr.Multiaddr)
ListenClose is called when network starts listening on an addr
func (*ConnectionNotifee) OpenedStream ¶
func (cn *ConnectionNotifee) OpenedStream(netw network.Network, stream network.Stream)
OpenedStream is called when a stream opened
type DiscoveryNotifee ¶
type DiscoveryNotifee struct { Host host.Host Dht *dht.IpfsDHT HandleConnect func(*host.Host, *peer.AddrInfo) }
func (*DiscoveryNotifee) HandlePeerFound ¶
func (n *DiscoveryNotifee) HandlePeerFound(pi peer.AddrInfo)
Click to show internal directories.
Click to hide internal directories.