flagenv

package
v0.0.57-rc.2 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

View Source
var CommandLine = NewFlagEnvSet(os.Args[0], flag.ExitOnError)

CommandLine is the default set of command-line flags, parsed from os.Args. The top-level functions such as BoolVar, Arg, and so on are wrappers for the methods of CommandLine.

Functions

func Bool

func Bool(name string, environ string, value bool, usage string) *bool

func BoolVar

func BoolVar(p *bool, name string, environ string, value bool, usage string)

func Float64

func Float64(name string, environ string, value float64, usage string) *float64

func Float64Var

func Float64Var(p *float64, name string, environ string, value float64, usage string)

func Int

func Int(name string, environ string, value int, usage string) *int

func Int64

func Int64(name string, environ string, value int64, usage string) *int64

func Int64Var

func Int64Var(p *int64, name string, environ string, value int64, usage string)

func IntVar

func IntVar(p *int, name string, environ string, value int, usage string)

func Second

func Second(name string, environ string, value time.Duration, usage string) *time.Duration

func SecondVar

func SecondVar(p *time.Duration, name string, environ string, value time.Duration, usage string)

func String

func String(name string, environ string, value string, usage string) *string

func StringVar

func StringVar(p *string, name string, environ string, value string, usage string)

func Uint

func Uint(name string, environ string, value uint, usage string) *uint

func Uint64

func Uint64(name string, environ string, value uint64, usage string) *uint64

func Uint64Var

func Uint64Var(p *uint64, name string, environ string, value uint64, usage string)

func UintVar

func UintVar(p *uint, name string, environ string, value uint, usage string)

Types

type FlagEnvSet

type FlagEnvSet struct {
	*flag.FlagSet
}

func NewFlagEnvSet

func NewFlagEnvSet(name string, errorHandling flag.ErrorHandling) *FlagEnvSet

func (*FlagEnvSet) Bool

func (s *FlagEnvSet) Bool(name string, environ string, value bool, usage string) *bool

func (*FlagEnvSet) BoolVar

func (s *FlagEnvSet) BoolVar(p *bool, name string, environ string, value bool, usage string)

func (*FlagEnvSet) Float64

func (s *FlagEnvSet) Float64(name string, environ string, value float64, usage string) *float64

func (*FlagEnvSet) Float64Var

func (s *FlagEnvSet) Float64Var(p *float64, name string, environ string, value float64, usage string)

func (*FlagEnvSet) Int

func (s *FlagEnvSet) Int(name string, environ string, value int, usage string) *int

func (*FlagEnvSet) Int64

func (s *FlagEnvSet) Int64(name string, environ string, value int64, usage string) *int64

func (*FlagEnvSet) Int64Var

func (s *FlagEnvSet) Int64Var(p *int64, name string, environ string, value int64, usage string)

func (*FlagEnvSet) IntVar

func (s *FlagEnvSet) IntVar(p *int, name string, environ string, value int, usage string)

func (*FlagEnvSet) Second

func (s *FlagEnvSet) Second(name string, environ string, value time.Duration, usage string) *time.Duration

func (*FlagEnvSet) SecondVar

func (s *FlagEnvSet) SecondVar(p *time.Duration, name string, environ string, value time.Duration, usage string)

func (*FlagEnvSet) String

func (s *FlagEnvSet) String(name string, environ string, value string, usage string) *string

func (*FlagEnvSet) StringVar

func (s *FlagEnvSet) StringVar(p *string, name string, environ string, value string, usage string)

func (*FlagEnvSet) Uint

func (s *FlagEnvSet) Uint(name string, environ string, value uint, usage string) *uint

func (*FlagEnvSet) Uint64

func (s *FlagEnvSet) Uint64(name string, environ string, value uint64, usage string) *uint64

func (*FlagEnvSet) Uint64Var

func (s *FlagEnvSet) Uint64Var(p *uint64, name string, environ string, value uint64, usage string)

func (*FlagEnvSet) UintVar

func (s *FlagEnvSet) UintVar(p *uint, name string, environ string, value uint, usage string)

Jump to

Keyboard shortcuts

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