knet

package
v0.1.4 Latest Latest
Warning

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

Go to latest
Published: Jan 13, 2022 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetPeerIP

func GetPeerIP(ctx context.Context) string

GetPeerIP 获取对端ip

func GrpcHeaderValue

func GrpcHeaderValue(ctx context.Context, key string) string

GrpcHeaderValue 获取context value

func InetAtoN

func InetAtoN(ip string) int64

func InetNtoA

func InetNtoA(ip int64) string

func IsPrivateIP

func IsPrivateIP(ip net.IP) bool

func Local

func Local() (ip string, err error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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