flags

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Aug 14, 2022 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func All

func All[T any](xs []T, f func(x T) bool) bool

func Any

func Any[T any](xs []T, f func(x T) bool) bool

func Includes

func Includes[T comparable](xs []T, n T) bool

func StringSliceEnumVarP

func StringSliceEnumVarP(flags *pflag.FlagSet, p *[]string, name string, shorthand string, defaults []string, usage string, options []string) *pflag.Flag

func StringSliceWithValidationVarP

func StringSliceWithValidationVarP(flags *pflag.FlagSet, p *[]string, name string, shorthand string, defaults []string, usage string, validator func([]string) error) *pflag.Flag

Types

type StringSliceValueWithValidation

type StringSliceValueWithValidation struct {
	Values    *[]string
	Validator func([]string) error
}

func (*StringSliceValueWithValidation) Set

func (*StringSliceValueWithValidation) String

func (*StringSliceValueWithValidation) Type

Jump to

Keyboard shortcuts

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