Documentation
¶
Index ¶
- type Bool
- func (s *Bool) ApplyToFlagSet(name string, flags *pflag.FlagSet)
- func (s *Bool) GetDefault() interface{}
- func (s *Bool) GetShorthand() string
- func (s *Bool) GetUsage() string
- func (s *Bool) GetValue() interface{}
- func (s *Bool) GetValuePointer() interface{}
- func (s *Bool) SetValue(value interface{})
- type Config
- type Float
- func (s *Float) ApplyToFlagSet(name string, flags *pflag.FlagSet)
- func (s *Float) GetDefault() interface{}
- func (s *Float) GetShorthand() string
- func (s *Float) GetUsage() string
- func (s *Float) GetValue() interface{}
- func (s *Float) GetValuePointer() interface{}
- func (s *Float) SetValue(value interface{})
- type Int
- type IntSlice
- func (s *IntSlice) ApplyToFlagSet(name string, flags *pflag.FlagSet)
- func (s *IntSlice) GetDefault() interface{}
- func (s *IntSlice) GetShorthand() string
- func (s *IntSlice) GetUsage() string
- func (s *IntSlice) GetValue() interface{}
- func (s *IntSlice) GetValuePointer() interface{}
- func (s *IntSlice) SetValue(value interface{})
- type Map
- func (m *Map) ApplyToCobra(command *cobra.Command)
- func (m *Map) ApplyToCobraPersistent(command *cobra.Command)
- func (m *Map) ApplyToFlagSet(flags *pflag.FlagSet)
- func (m Map) Get(id string) interface{}
- func (m Map) GetBool(id string) bool
- func (m Map) GetFloat(id string) float64
- func (m Map) GetInt(id string) int
- func (m Map) GetIntSlice(id string) []int
- func (m Map) GetString(id string) string
- func (m Map) GetStringSlice(id string) []string
- func (m Map) GetUint(id string) uint
- func (m Map) GetUintSlice(id string) []uint
- func (m *Map) LoadFromEnvironment()
- type String
- func (s *String) ApplyToFlagSet(name string, flags *pflag.FlagSet)
- func (s *String) GetDefault() interface{}
- func (s *String) GetShorthand() string
- func (s *String) GetUsage() string
- func (s *String) GetValue() interface{}
- func (s *String) GetValuePointer() interface{}
- func (s *String) SetValue(value interface{})
- type StringSlice
- func (s *StringSlice) ApplyToFlagSet(name string, flags *pflag.FlagSet)
- func (s *StringSlice) GetDefault() interface{}
- func (s *StringSlice) GetShorthand() string
- func (s *StringSlice) GetUsage() string
- func (s *StringSlice) GetValue() interface{}
- func (s *StringSlice) GetValuePointer() interface{}
- func (s *StringSlice) SetValue(value interface{})
- type Uint
- func (s *Uint) ApplyToFlagSet(name string, flags *pflag.FlagSet)
- func (s *Uint) GetDefault() interface{}
- func (s *Uint) GetShorthand() string
- func (s *Uint) GetUsage() string
- func (s *Uint) GetValue() interface{}
- func (s *Uint) GetValuePointer() interface{}
- func (s *Uint) SetValue(value interface{})
- type UintSlice
- func (s *UintSlice) ApplyToFlagSet(name string, flags *pflag.FlagSet)
- func (s *UintSlice) GetDefault() interface{}
- func (s *UintSlice) GetShorthand() string
- func (s *UintSlice) GetUsage() string
- func (s *UintSlice) GetValue() interface{}
- func (s *UintSlice) GetValuePointer() interface{}
- func (s *UintSlice) SetValue(value interface{})
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Bool ¶
Bool represents a configuration which should be interpreted as a boolean-typed value
func (*Bool) ApplyToFlagSet ¶
ApplyToFlagSet applies the configuration to a provided flag set
func (*Bool) GetDefault ¶
func (s *Bool) GetDefault() interface{}
GetDefault retrieves the default value of this configuration
func (*Bool) GetShorthand ¶
GetShorthand retrieves the short form of the flag if available
func (*Bool) GetValue ¶
func (s *Bool) GetValue() interface{}
GetValue returns the value of this configuration
func (*Bool) GetValuePointer ¶
func (s *Bool) GetValuePointer() interface{}
GetValuePointer returns a pointer that points to the instance of the configured value
type Float ¶
Float stores the configuration details for a floating point value
func (*Float) ApplyToFlagSet ¶
ApplyToFlagSet applies the configuration to a provided flag set
func (*Float) GetDefault ¶
func (s *Float) GetDefault() interface{}
GetDefault retrieves the default value of this configuration
func (*Float) GetShorthand ¶
GetShorthand retrieves the short form of the flag if available
func (*Float) GetValue ¶
func (s *Float) GetValue() interface{}
GetValue returns the value of this configuration
func (*Float) GetValuePointer ¶
func (s *Float) GetValuePointer() interface{}
GetValuePointer returns a pointer that points to the instance of the configured value
type Int ¶
Int represents a configuration which should be interpreted as a signed integer
func (*Int) ApplyToFlagSet ¶
ApplyToFlagSet applies the configuration to a provided flag set
func (*Int) GetDefault ¶
func (s *Int) GetDefault() interface{}
GetDefault retrieves the default value of this configuration
func (*Int) GetShorthand ¶
GetShorthand retrieves the short form of the flag if available
func (*Int) GetValue ¶
func (s *Int) GetValue() interface{}
GetValue returns the value of this configuration
func (*Int) GetValuePointer ¶
func (s *Int) GetValuePointer() interface{}
GetValuePointer returns a pointer that points to the instance of the configured value
type IntSlice ¶
IntSlice represents a configuration which should be interpreted as a slice of signed integers
func (*IntSlice) ApplyToFlagSet ¶
ApplyToFlagSet applies the configuration to a provided flag set
func (*IntSlice) GetDefault ¶
func (s *IntSlice) GetDefault() interface{}
GetDefault retrieves the default value of this configuration
func (*IntSlice) GetShorthand ¶
GetShorthand retrieves the short form of the flag if available
func (*IntSlice) GetValue ¶
func (s *IntSlice) GetValue() interface{}
GetValue returns the value of this configuration
func (*IntSlice) GetValuePointer ¶
func (s *IntSlice) GetValuePointer() interface{}
GetValuePointer returns a pointer that points to the instance of the configured value
type Map ¶
func (*Map) ApplyToCobra ¶
func (*Map) ApplyToCobraPersistent ¶ added in v0.1.20
func (*Map) ApplyToFlagSet ¶ added in v0.1.20
func (Map) GetIntSlice ¶
func (Map) GetStringSlice ¶
func (Map) GetUintSlice ¶
func (*Map) LoadFromEnvironment ¶
func (m *Map) LoadFromEnvironment()
type String ¶
String represents a configuration which should be interpreted as a string-typed value
func (*String) ApplyToFlagSet ¶
ApplyToFlagSet applies the configuration to a provided flag set
func (*String) GetDefault ¶
func (s *String) GetDefault() interface{}
GetDefault retrieves the default value of this configuration
func (*String) GetShorthand ¶
GetShorthand retrieves the short form of the flag if available
func (*String) GetValue ¶
func (s *String) GetValue() interface{}
GetValue returns the value of this configuration
func (*String) GetValuePointer ¶
func (s *String) GetValuePointer() interface{}
GetValuePointer returns a pointer that points to the instance of the configured value
type StringSlice ¶
StringSlice represents a configuration which should be represented as a slice of strings
func (*StringSlice) ApplyToFlagSet ¶
func (s *StringSlice) ApplyToFlagSet(name string, flags *pflag.FlagSet)
// ApplyToFlagSet applies the configuration to a provided flag set
func (*StringSlice) GetDefault ¶
func (s *StringSlice) GetDefault() interface{}
GetDefault retrieves the default value of this configuration
func (*StringSlice) GetShorthand ¶
func (s *StringSlice) GetShorthand() string
GetShorthand retrieves the short form of the flag if available
func (*StringSlice) GetUsage ¶
func (s *StringSlice) GetUsage() string
GetUsage retrieves the usage string for this configuration
func (*StringSlice) GetValue ¶
func (s *StringSlice) GetValue() interface{}
GetValue returns the value of this configuration
func (*StringSlice) GetValuePointer ¶
func (s *StringSlice) GetValuePointer() interface{}
GetValuePointer returns a pointer that points to the instance of the configured value
func (*StringSlice) SetValue ¶
func (s *StringSlice) SetValue(value interface{})
SetValue sets the value of this configuration
type Uint ¶
Uint represents a configuration which should be interpreted as an unsigned integer
func (*Uint) ApplyToFlagSet ¶
ApplyToFlagSet applies the configuration to a provided flag set
func (*Uint) GetDefault ¶
func (s *Uint) GetDefault() interface{}
GetDefault retrieves the default value of this configuration
func (*Uint) GetShorthand ¶
GetShorthand retrieves the short form of the flag if available
func (*Uint) GetValue ¶
func (s *Uint) GetValue() interface{}
GetValue returns the value of this configuration
func (*Uint) GetValuePointer ¶
func (s *Uint) GetValuePointer() interface{}
GetValuePointer returns a pointer that points to the instance of the configured value
type UintSlice ¶
UintSlice represents a configuration which should be interpreted as a slice of unsigned integers
func (*UintSlice) ApplyToFlagSet ¶
ApplyToFlagSet applies the configuration to a provided flag set
func (*UintSlice) GetDefault ¶
func (s *UintSlice) GetDefault() interface{}
GetDefault retrieves the default value of this configuration
func (*UintSlice) GetShorthand ¶
GetShorthand retrieves the short form of the flag if available
func (*UintSlice) GetValue ¶
func (s *UintSlice) GetValue() interface{}
GetValue returns the value of this configuration
func (*UintSlice) GetValuePointer ¶
func (s *UintSlice) GetValuePointer() interface{}
GetValuePointer returns a pointer that points to the instance of the configured value