words

package
v0.0.0-...-e0ac0b4 Latest Latest
Warning

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

Go to latest
Published: Jul 17, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DeleteWordList

func DeleteWordList(filePath string) error

func DownloadFile

func DownloadFile(filepath string, url string) error

func EnsureDir

func EnsureDir(fileName string) error

func LoadWordList

func LoadWordList(filePath string, wordSourceToFill WordSource) error

Types

type Metadata

type Metadata struct {
	Name       string
	Size       int
	PackagedAt string //Use some kind of date type here?
	Version    int
}

type WordSource

type WordSource struct {
	Metadata Metadata
	Words    []string
}

func LoadWordSources

func LoadWordSources(paths []string) ([]WordSource, error)

type WordsGenerator

type WordsGenerator struct {
	Count int
	// contains filtered or unexported fields
}

func NewGenerator

func NewGenerator(paths []string) (g WordsGenerator)

func (WordsGenerator) Generate

func (this WordsGenerator) Generate(listName string) []rune

Jump to

Keyboard shortcuts

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