generate

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Feb 20, 2021 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RandomChar

type RandomChar struct {
	Char     string
	Charfreq int
	Chance   string
}

type WordLength

type WordLength struct {
	// contains filtered or unexported fields
}

type WorldList

type WorldList struct {
	Length  int
	Chance  string
	Word    string
	CharMap []RandomChar
}

func GenRandomLower

func GenRandomLower(length int) (WorldList, error)

lower

func GenRandomMix

func GenRandomMix(length int) (WorldList, error)

mix

func GenRandomNone

func GenRandomNone(length int) (WorldList, error)

none

func GenRandomTitle

func GenRandomTitle(length int) (WorldList, error)

title

func GenRandomUpper

func GenRandomUpper(length int) (WorldList, error)

upper

func GenRandomWorld

func GenRandomWorld(length int, model string) (WorldList, error)

GenRandomWorld returns a random word by convention, The length must be between 0 and 19. The model must be : none,upper,lower,mix,title none: String lowercase upper: String uppercase lower: String lowercase mix: String random case title: String First case

Jump to

Keyboard shortcuts

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