Documentation ¶
Index ¶
Constants ¶
View Source
const ID = "/qlc/ping/1.0.0"
View Source
const (
PingSize = 32
)
Variables ¶
View Source
var ErrPingSelf = errors.New("cannot ping self")
ErrPingSelf is returned if the pinger is instructed to ping itself.
Functions ¶
Types ¶
type PingService ¶
func NewPingService ¶
func NewPingService(h host.Host) *PingService
func (*PingService) PingHandler ¶
func (p *PingService) PingHandler(s network.Stream)
type Pinger ¶
type Pinger struct { *PingService // contains filtered or unexported fields }
Pinger wraps a libp2p ping service. It exists to serve more helpful error messages in the case a node is pinging itself.
Click to show internal directories.
Click to hide internal directories.