strings

package module
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2023 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Rand

type Rand interface {
	// Rand returns random generated string with settled options.
	Rand(...RandOpt) string

	// SetDict sets dict of string randomizer.
	SetDict(RandDict) Rand

	// SetSize sets size of string randomizer.
	SetSize(RandSize) Rand
	// contains filtered or unexported methods
}

Rand describes string randomizer interface.

func NewRand

func NewRand(opts ...RandOpt) Rand

NewRand returns constructed string randomizer.

type RandDict

type RandDict string

RandDict describes dictionary option of string randomizer.

const (
	DefaultRandDict RandDict = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"
)

type RandOpt

type RandOpt interface {
	// contains filtered or unexported methods
}

RandOpt option interface of string randomizer.

type RandSize

type RandSize uint

RandSize describes size option of string randomizer.

Jump to

Keyboard shortcuts

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