alphabet

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Overview

Package alphabet provides API for manipulating with the list of defined characters

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Alphabet

type Alphabet interface {
	// Has tells is given char exists in alphabet
	Has(char rune) bool
	// Size returns the size of alphabet
	Size() int
	// Chars returns the current set of symbols
	Chars() []rune
}

Alphabet is abstract for manipulating with set of symbols

func CreateAlphabet

func CreateAlphabet(description []string) Alphabet

CreateAlphabet creates alphabet from a string declaration

func NewCompositeAlphabet

func NewCompositeAlphabet(alphabets []Alphabet) Alphabet

NewCompositeAlphabet returns new instance of compositeAlphabet

func NewEnglishAlphabet

func NewEnglishAlphabet() Alphabet

NewEnglishAlphabet returns new instance of englishAlphabet

func NewNumberAlphabet

func NewNumberAlphabet() Alphabet

NewNumberAlphabet returns new instance of numberAlphabet

func NewRussianAlphabet

func NewRussianAlphabet() Alphabet

NewRussianAlphabet returns new instance of RussianAlphabet

func NewSequentialAlphabet

func NewSequentialAlphabet(min, max rune) Alphabet

NewSequentialAlphabet returns new instance of sequentialAlphabet

func NewSimpleAlphabet

func NewSimpleAlphabet(chars []rune) Alphabet

NewSimpleAlphabet returns new instance of SimpleAlphabet

Jump to

Keyboard shortcuts

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