random

package
v1.0.8 Latest Latest
Warning

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

Go to latest
Published: Jun 29, 2023 License: Apache-2.0 Imports: 2 Imported by: 8

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RandDigits

func RandDigits(n int) string

func RandDigitsRange

func RandDigitsRange(min, max int) string

RandDigitsRange generates a random numeric string of length [min,max).

func RandHex

func RandHex(n int) string

func RandHexRange

func RandHexRange(min, max int) string

RandHexRange generates a random hex string of length [min,max).

func RandIntRange added in v1.0.6

func RandIntRange(min, max int) int

RandIntRange generates an `int` between [min,max).

func RandLetters

func RandLetters(n int) string

func RandLettersRange

func RandLettersRange(min, max int) string

RandLettersRange generates a random alpha string of length [min,max).

func RandPositiveInt added in v1.0.6

func RandPositiveInt(max int) int

RandPositiveInt generates a non-negative crypto-random number in the half-open interval [0,max).

Types

This section is empty.

Jump to

Keyboard shortcuts

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