locale

package
v0.0.0-...-732dc05 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2025 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Numbers      = []rune("0123456789")
	SpecialChars = []rune("!#$%&()*+,-.:;<=>?@_{|}")
)

Functions

func SortPhones

func SortPhones(phonePatterns []string)

Types

type Gender

type Gender int
const (
	FemaleGender Gender = iota
	MaleGender
	AnyGender
	WordsDelimiter = " "
)

type LocalModule

type LocalModule interface {
	// SmallLetters should return small letters of selected language
	SmallLetters() []rune
	// LargeLetters should return large letters of selected language
	LargeLetters() []rune
	// GetFirstNames should return first names
	GetFirstNames(gender Gender) []string
	// GetLastNames should return last names
	GetLastNames(gender Gender) []string
	// GetPhonePatterns should return country phone patterns
	GetPhonePatterns() []string
	// GetBytesPerChar should return how many bytes per char of selected language
	GetBytesPerChar() int
	// GetWords should return words of selected language
	GetWords() []string
	// GetOneLetterWords should return one-letter words of selected language
	GetOneLetterWords() []string
}

LocalModule interface implementation should have strings for selected locale.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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