vrandom

package
v0.0.0-...-0b57644 Latest Latest
Warning

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

Go to latest
Published: Sep 3, 2020 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	KeyTableDefault = "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"
	KeyTableAlpha   = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"
	KeyTableNumeric = "0123456789"
)

Variables

This section is empty.

Functions

func GetUUIDv1

func GetUUIDv1() string

生成UUIDv1

func GetUUIDv4

func GetUUIDv4() string

生成UUIDv4

func IntArrayRandom

func IntArrayRandom(src []int) []int

打乱一个数组,使用Fisher-Yates算法

func RandomAlpha

func RandomAlpha(saltlen int) string

RandomAlpha 生成随机字符串

func RandomDefault

func RandomDefault(saltlen int) string

RandomDefault 生成随机字符串

func RandomInt

func RandomInt(min, max int) int

返回一个min,max之间的随机Int

func RandomNumber

func RandomNumber(length int) string

RandomNumber 生成随机数字

func RandomNumberDefault

func RandomNumberDefault() string

RandomNumberDefault 生成6位随机数字

Types

This section is empty.

Jump to

Keyboard shortcuts

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