functions

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Mar 15, 2023 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateRandomNumber

func CreateRandomNumber(count int) string

生成指定位数的随机数字

func CreateRandomString

func CreateRandomString(count int) string

生成指定长度的随机字符串

func GetAccountIdFromToken

func GetAccountIdFromToken(tokenStr string, key []byte) (accoutId string, err error)

func GetIdlePorts

func GetIdlePorts(count int, start int) []int

func GetIntV

func GetIntV(i interface{}) (int, error)

func IsIntranet

func IsIntranet(ip string) bool

IsIntranet 判断是否是内网

func IsLocalIP

func IsLocalIP(ip string) (bool, error)

判断IP是否是本地的IP(IPV4和IPV6)

func LocalPortMap

func LocalPortMap(src int, dest int, ctx context.Context) (err error)

本地端口映射

func PathSplit

func PathSplit(path string) []string

Types

This section is empty.

Jump to

Keyboard shortcuts

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