Documentation ¶
Index ¶
- func ExtractHost(hostport string) (net.IP, error)
- func GetAvailableIPs() (availableIPs []net.IP, err error)
- func GetPublicIPs() ([]net.IP, error)
- func IsIPv4(ip net.IP) bool
- func IsPrivateIP(ip net.IP) bool
- func LookupTCPHostPort(hostport string) ([]net.Addr, error)
- func SortedIPs(ips []string) []string
- type Port
- type TCPAddr
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetAvailableIPs ¶
func GetPublicIPs ¶ added in v0.4.10
func IsPrivateIP ¶
Types ¶
type Port ¶
type Port uint16
Port describes a transport layer port.
func ExtractPort ¶
func SplitHostPort ¶
SplitHostPort splits a network address.
A literal address or host name for IPv6 must be enclosed in square brackets, as in "[::1]:80".
Unlike net.SplitHostPort this function also performs type transformations to represent an IP address as a commonly-used interface and a port as an uint16.
Click to show internal directories.
Click to hide internal directories.