pflagfork

package
v0.33.2 Latest Latest
Warning

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

Go to latest
Published: Feb 5, 2023 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Default         style = iota // default behaviour
	ShorthandOnly                // only the shorthand should be used
	NameAsShorthand              // non-posix style where the name is also added as shorthand (single `-` prefix)
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Flag added in v0.26.0

type Flag struct {
	*pflag.Flag
}

func (Flag) IsOptarg added in v0.31.1

func (f Flag) IsOptarg() bool

func (Flag) IsRepeatable added in v0.29.3

func (f Flag) IsRepeatable() bool

func (Flag) Matches added in v0.32.0

func (f Flag) Matches(arg string, posix bool) bool

func (Flag) Nargs added in v0.33.0

func (f Flag) Nargs() int

func (Flag) OptargDelimiter added in v0.32.0

func (f Flag) OptargDelimiter() rune

func (Flag) Split added in v0.32.0

func (f Flag) Split(arg string) (prefix, optarg string)

func (Flag) Style added in v0.29.3

func (f Flag) Style() style

func (Flag) TakesValue added in v0.31.1

func (f Flag) TakesValue() bool

type FlagSet added in v0.26.0

type FlagSet struct {
	*pflag.FlagSet
}

func (FlagSet) IsMutuallyExclusive added in v0.29.3

func (f FlagSet) IsMutuallyExclusive(flag *pflag.Flag) bool

func (FlagSet) IsPosix added in v0.29.3

func (f FlagSet) IsPosix() bool

func (FlagSet) IsShorthandSeries added in v0.32.0

func (f FlagSet) IsShorthandSeries(arg string) bool

func (FlagSet) LookupArg added in v0.32.0

func (fs FlagSet) LookupArg(arg string) (result *Flag)

func (*FlagSet) VisitAll added in v0.29.3

func (f *FlagSet) VisitAll(fn func(*Flag))

Jump to

Keyboard shortcuts

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