net

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Jan 23, 2025 License: MIT, Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CommonIPV4 added in v0.3.9

func CommonIPV4() (string, error)

func CommonIPv6 added in v0.3.9

func CommonIPv6() (string, error)

获取当前公网 IPv6 地址

func ExternalIP

func ExternalIP() (net.IP, error)

func ExternalIPString

func ExternalIPString() string

func IPStrToUint32 added in v0.0.25

func IPStrToUint32(ipStr string) (uint32, error)

func IPv4Address added in v0.3.9

func IPv4Address() ([]string, error)

func IPv4ToUint32 added in v0.0.25

func IPv4ToUint32(ip net.IP) (uint32, error)

func IPv6Addresses added in v0.3.9

func IPv6Addresses() ([]string, error)

func IPv6s added in v0.3.9

func IPv6s() ([]net.IP, error)

func LocalIPv4Address

func LocalIPv4Address() ([]string, error)

获取本机ip地址

func LocalIPv6Addresses added in v0.3.9

func LocalIPv6Addresses() ([]string, error)

func Uint32ToIPStr added in v0.0.25

func Uint32ToIPStr(ipInt uint32) (string, error)

func Uint32ToIPv4 added in v0.0.25

func Uint32ToIPv4(ipInt uint32) (net.IP, error)

Types

type StrAddr

type StrAddr string

func (StrAddr) Network

func (a StrAddr) Network() string

func (StrAddr) String

func (a StrAddr) String() string

Directories

Path Synopsis
fs
gin
grpc/web
`grpcweb` implements the gRPC-Web spec as a wrapper around a gRPC-Go Server.
`grpcweb` implements the gRPC-Web spec as a wrapper around a gRPC-Go Server.
log
router
Package httprouter is a trie based high performance HTTP request router.
Package httprouter is a trie based high performance HTTP request router.

Jump to

Keyboard shortcuts

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