enumer

package module
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jun 10, 2022 License: MIT Imports: 4 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNotInEnumeration = errors.New("not in enumeration")

Functions

This section is empty.

Types

type Enum

type Enum[T V] []T

func New

func New[T V](ts ...T) Enum[T]

func (Enum[T]) Contains

func (ts Enum[T]) Contains(s string) bool

func (Enum[T]) Parse

func (ts Enum[T]) Parse(s string) (T, error)

func (Enum[T]) String

func (ts Enum[T]) String() string

func (Enum[T]) ToString

func (ts Enum[T]) ToString() []string

type V

type V interface {
	~string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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