Documentation ¶
Index ¶
Constants ¶
View Source
const (
TIMEOUTERR = unix.EWOULDBLOCK
)
Variables ¶
View Source
var ( ErrNotIPV4 = errors.New("the given address is not IPv4") ErrNotIPV6 = errors.New("the given address is not IPv6") )
Functions ¶
This section is empty.
Types ¶
type Pingsocket ¶
type Pingsocket interface { SetTTL(ttl uint8) error Close() error SetReadTimeout(duration time.Duration) error SendTo(packet []byte, destination net.IP) error Recvfrom(buf []byte) (n int, from net.IP, err error) }
func SocketForAddress ¶
func SocketForAddress(address net.IP) (Pingsocket, error)
Click to show internal directories.
Click to hide internal directories.