rand

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Feb 13, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateRandomBytes added in v0.1.0

func GenerateRandomBytes() ([]byte, error)

GenerateRandomBytes returns a random []byte.

func New

func New() []byte

New creates a new random []byte or panics.

func NewBase32

func NewBase32() string

NewBase32 creates a new random []byte and returns it as a base32 string or panics.

func NewBase32WithLength

func NewBase32WithLength(length int) string

NewBase32WithLength creates a new random []byte and returns it as a base32 string or panics.

func NewBase62 added in v0.1.0

func NewBase62() string

NewBase62 creates a new random []byte and returns it as a base62 string or panics.

func NewBase62WithLength added in v0.1.0

func NewBase62WithLength(length int) string

NewBase62WithLength creates a new random []byte and returns it as a base62 string or panics.

func NewBase64

func NewBase64() string

NewBase64 creates a new random []byte and returns it as a base64 string or panics.

func NewBase64WithLength

func NewBase64WithLength(length int) string

NewBase64WithLength creates a new random []byte and returns it as a base64 string or panics.

func NewHex

func NewHex() string

NewHex creates a new random []byte and returns it as a hex string or panics.

func NewHexWithLength

func NewHexWithLength(length int) string

NewHexWithLength creates a new random []byte and returns it as a hex string or panics.

func NewWithLength

func NewWithLength(length int) []byte

NewWithLength creates a new random []byte or panics.

Types

This section is empty.

Jump to

Keyboard shortcuts

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