utils

package
v0.4.2 Latest Latest
Warning

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

Go to latest
Published: Nov 2, 2023 License: MPL-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Quote

func Quote(value string, q rune) string

func QuoteBuilder

func QuoteBuilder(out interface{ WriteRune(rune) (int, error) }, value string, q rune)

func TemplateFuncs

func TemplateFuncs() template.FuncMap

func Uniq

func Uniq[T comparable](values []T) []T

Types

type Set

type Set[T comparable] map[T]struct{}

func NewSet

func NewSet[T comparable](values ...T) Set[T]

func (Set[T]) Add

func (s Set[T]) Add(values ...T)

func (Set[T]) Has

func (s Set[T]) Has(values ...T) bool

func (*Set[T]) UnmarshalYAML added in v0.4.0

func (s *Set[T]) UnmarshalYAML(value *yaml.Node) error

Jump to

Keyboard shortcuts

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