Documentation
¶
Index ¶
- Constants
- Variables
- func ExtractHostPort(addr string) (host string, port uint64, err error)
- func GetAvaliableAddr(logger xlog.Logger, localIp string, addr string) (newAddr string, err error)
- func GetLocalIP(masks ...string) string
- func GetLocalMac(masks ...string) string
- func IsLocalIPv4(ip net.IP) bool
- func IsLocalIPv4Addr(ip string) bool
- func IsValidIP(addr string) bool
- func Parse(addr string) (proto, name string, err error)
- func ScanPort(protocol string, hostname string, port int64) bool
- type PortPicker
Constants ¶
View Source
const StaticLocalIP = "127.0.0.1"
View Source
const StaticLocalMac = "00:1A:2B:3C:4D:5E"
Variables ¶
View Source
var GetInterfaces = defaultGetInterfaces
Functions ¶
func ExtractHostPort ¶ added in v0.1.1
ExtractHostPort from address
func GetAvaliableAddr ¶ added in v0.1.25
:8080 [2000,30000) [2000,30000):rand [2000,30000):seq:5
func GetLocalMac ¶ added in v0.2.6
Types ¶
Click to show internal directories.
Click to hide internal directories.