ping

package
v0.1.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 13, 2025 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Ping

type Ping struct {
	Options *statute.ScannerOptions
}

func (*Ping) DoPing

func (p *Ping) DoPing(ctx context.Context, ip netip.Addr) (statute.IPInfo, error)

DoPing performs a ping on the given IP address.

type WarpPing

type WarpPing struct {
	PrivateKey    string
	PeerPublicKey string
	PresharedKey  string
	IP            netip.Addr
}

func NewWarpPing

func NewWarpPing(ip netip.Addr, opts *statute.ScannerOptions) *WarpPing

func (*WarpPing) Ping

func (h *WarpPing) Ping() statute.IPingResult

func (*WarpPing) PingContext

func (h *WarpPing) PingContext(ctx context.Context) statute.IPingResult

type WarpPingResult

type WarpPingResult struct {
	AddrPort netip.AddrPort
	RTT      time.Duration
	Err      error
}

func (*WarpPingResult) Error

func (h *WarpPingResult) Error() error

func (*WarpPingResult) Result

func (h *WarpPingResult) Result() statute.IPInfo

func (*WarpPingResult) String

func (h *WarpPingResult) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL