enum

package
v0.0.0-...-23d24bf Latest Latest
Warning

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

Go to latest
Published: Feb 6, 2024 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EnumString

func EnumString[T fmt.Stringer](values []T) string

EnumString returns a comma-separated string of the enum values. This is primarily used to generate a cli flag.

Types

type Stringered

type Stringered string

Stringered wraps the string type to implement the fmt.Stringer interface.

func StringeredList

func StringeredList(values []string) []Stringered

StringeredList converts a list of strings to a list of Stringered.

func (Stringered) String

func (s Stringered) String() string

String returns the string value.

Jump to

Keyboard shortcuts

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