flagsplugin

package
v1.2.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Base64Replacer = strings.NewReplacer("_", "/", "-", "+")

Base64Replacer transforms the string to RawStdEncoding string

Functions

func AddAlias

func AddAlias(flagSet *pflag.FlagSet, flagName, aliasName string, opts ...FlagOption)

AddAlias creates a flag with different name that points to another flag. Setting this flag will update the value in the child flag.

func ApplyOptions

func ApplyOptions(f *pflag.Flag, opts ...FlagOption)

ApplyOptions applies flag options to the passed flag.

func EnumValueDesc

func EnumValueDesc(valueMaps ...map[string]int32) string

EnumValueDesc returns a string with possible values for enum.

func GetBool

func GetBool(fs *pflag.FlagSet, name string) (value bool, set bool, err error)

GetBool returns a value from a bool flag.

func GetBoolSlice

func GetBoolSlice(fs *pflag.FlagSet, name string) (value []bool, set bool, err error)

GetBoolSlice returns a value from a bool slice flag.

func GetBytes

func GetBytes(fs *pflag.FlagSet, name string) (value []byte, set bool, err error)

GetBytes returns a value from a bytes flag.

func GetBytesSlice

func GetBytesSlice(fs *pflag.FlagSet, name string) (value [][]byte, set bool, err error)

GetBytesSlice returns a value from a byte slice flag.

func GetDuration

func GetDuration(fs *pflag.FlagSet, name string) (value time.Duration, set bool, err error)

GetDuration returns a value from a duration flag.

func GetDurationSlice

func GetDurationSlice(fs *pflag.FlagSet, name string) (value []time.Duration, set bool, err error)

GetDurationSlice returns a value from a duration slice flag.

func GetFloat32

func GetFloat32(fs *pflag.FlagSet, name string) (value float32, set bool, err error)

GetFloat32 returns a value from a float32 flag.

func GetFloat32Slice

func GetFloat32Slice(fs *pflag.FlagSet, name string) (value []float32, set bool, err error)

GetFloat32Slice returns a value from a float32 slice flag.

func GetFloat64

func GetFloat64(fs *pflag.FlagSet, name string) (value float64, set bool, err error)

GetFloat64 returns a value from a float64 flag.

func GetFloat64Slice

func GetFloat64Slice(fs *pflag.FlagSet, name string) (value []float64, set bool, err error)

GetFloat64Slice returns a value from a float64 slice flag.

func GetInt32

func GetInt32(fs *pflag.FlagSet, name string) (value int32, set bool, err error)

GetInt32 returns a value from a int32 flag.

func GetInt32Slice

func GetInt32Slice(fs *pflag.FlagSet, name string) (value []int32, set bool, err error)

GetInt32Slice returns a value from a int32 slice flag.

func GetInt64

func GetInt64(fs *pflag.FlagSet, name string) (value int64, set bool, err error)

GetInt64 returns a value from a int64 flag.

func GetInt64Slice

func GetInt64Slice(fs *pflag.FlagSet, name string) (value []int64, set bool, err error)

GetInt64Slice returns a value from a int64 slice flag.

func GetString

func GetString(fs *pflag.FlagSet, name string) (value string, set bool, err error)

GetString returns a value from a string flag.

func GetStringBoolMap

func GetStringBoolMap(fs *pflag.FlagSet, name string) (value map[string]bool, set bool, err error)

GetStringBoolMap returns a value from a string to bool map flag.

func GetStringBytesMap

func GetStringBytesMap(fs *pflag.FlagSet, name string) (value map[string][]byte, set bool, err error)

GetStringBytesMap returns a string to bytes map value from the flag.

func GetStringDurationMap

func GetStringDurationMap(fs *pflag.FlagSet, name string) (value map[string]time.Duration, set bool, err error)

GetStringDurationMap returns a value from a string to duration map flag.

func GetStringFloat32Map

func GetStringFloat32Map(fs *pflag.FlagSet, name string) (value map[string]float32, set bool, err error)

GetStringFloat32Map returns a value from a string to float32 map flag.

func GetStringFloat64Map

func GetStringFloat64Map(fs *pflag.FlagSet, name string) (value map[string]float64, set bool, err error)

GetStringFloat64Map returns a value from a string to float64 map flag.

func GetStringInt32Map

func GetStringInt32Map(fs *pflag.FlagSet, name string) (value map[string]int32, set bool, err error)

GetStringInt32Map returns a value from a string to int32 map flag.

func GetStringInt64Map

func GetStringInt64Map(fs *pflag.FlagSet, name string) (value map[string]int64, set bool, err error)

GetStringInt64Map returns a value from a string to int64 map flag.

func GetStringSlice

func GetStringSlice(fs *pflag.FlagSet, name string) (value []string, set bool, err error)

GetStringSlice returns a value from a string slice flag.

func GetStringStringMap

func GetStringStringMap(fs *pflag.FlagSet, name string) (value map[string]string, set bool, err error)

GetStringStringMap returns a value from a string to string map flag.

func GetStringTimestampMap

func GetStringTimestampMap(fs *pflag.FlagSet, name string) (value map[string]time.Time, set bool, err error)

GetStringTimestampMap returns a value from a string to time map flag.

func GetStringUint32Map

func GetStringUint32Map(fs *pflag.FlagSet, name string) (value map[string]uint32, set bool, err error)

GetStringUint32Map returns a value from a string to uint32 map flag.

func GetStringUint64Map

func GetStringUint64Map(fs *pflag.FlagSet, name string) (value map[string]uint64, set bool, err error)

GetStringUint64Map returns a value from a string to uint64 map flag.

func GetTimestamp

func GetTimestamp(fs *pflag.FlagSet, name string) (value time.Time, set bool, err error)

GetTimestamp returns a value from a time flag.

func GetTimestampSlice

func GetTimestampSlice(fs *pflag.FlagSet, name string) (value []time.Time, set bool, err error)

GetTimestampSlice returns a value from a time slice flag.

func GetUint32

func GetUint32(fs *pflag.FlagSet, name string) (value uint32, set bool, err error)

GetUint32 returns a value from a uint32 flag.

func GetUint32Slice

func GetUint32Slice(fs *pflag.FlagSet, name string) (value []uint32, set bool, err error)

GetUint32Slice returns a value from a uint32 slice flag.

func GetUint64

func GetUint64(fs *pflag.FlagSet, name string) (value uint64, set bool, err error)

GetUint64 returns a value from a uint64 flag.

func GetUint64Slice

func GetUint64Slice(fs *pflag.FlagSet, name string) (value []uint64, set bool, err error)

GetUint64Slice returns a value from a uint64 slice flag.

func IsAnyPrefixSet

func IsAnyPrefixSet(fs *pflag.FlagSet, prefix string) (flagSet bool)

IsAnyPrefixSet returns true if any flag with a supplied prefix is set.

func JoinSliceElements

func JoinSliceElements(elements []string) string

JoinSliceElements returns a comma separated string from a slice of strings.

func NewBase64BytesFlag

func NewBase64BytesFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewBase64BytesFlag defines a new flag with base64 encoded bytes value.

func NewBase64BytesSliceFlag

func NewBase64BytesSliceFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewBase64BytesSliceFlag defines a new base64 bytes slice flag.

func NewBoolFlag

func NewBoolFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewBoolFlag defines a new flag with bool value.

func NewBoolSliceFlag

func NewBoolSliceFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewBoolSliceFlag defines a new flag that holds a slice of bools.

func NewBytesFlag

func NewBytesFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewBytesFlag defines a new flag with base64 bytes value.

func NewBytesSliceFlag

func NewBytesSliceFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewBytesSliceFlag defines a new bytes slice flag.

func NewDurationFlag

func NewDurationFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewDurationFlag defines a new flag with bool value.

func NewDurationSliceFlag

func NewDurationSliceFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewDurationSliceFlag defines a new flag with bool slice value.

func NewFloat32Flag

func NewFloat32Flag(name, usage string, opts ...FlagOption) *pflag.Flag

NewFloat32Flag defines a new flag with float32 value.

func NewFloat32SliceFlag

func NewFloat32SliceFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewFloat32SliceFlag defines a new flag that holds a slice of float32 values.

func NewFloat64Flag

func NewFloat64Flag(name, usage string, opts ...FlagOption) *pflag.Flag

NewFloat64Flag defines a new flag with float64 value.

func NewFloat64SliceFlag

func NewFloat64SliceFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewFloat64SliceFlag defines a new flag that holds a slice of float64 values.

func NewHexBytesFlag

func NewHexBytesFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewHexBytesFlag defines a new flag with hex encoded bytes value.

func NewHexBytesSliceFlag

func NewHexBytesSliceFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewHexBytesSliceFlag defines a new hex bytes slice flag.

func NewInt32Flag

func NewInt32Flag(name, usage string, opts ...FlagOption) *pflag.Flag

NewInt32Flag defines a new flag with int32 value.

func NewInt32SliceFlag

func NewInt32SliceFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewInt32SliceFlag defines a new flag that holds a slice of int32 values.

func NewInt64Flag

func NewInt64Flag(name, usage string, opts ...FlagOption) *pflag.Flag

NewInt64Flag defines a new flag with int64 value.

func NewInt64SliceFlag

func NewInt64SliceFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewInt64SliceFlag defines a new flag that holds a slice of int64 values.

func NewStringBase64BytesMapFlag

func NewStringBase64BytesMapFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewStringBase64BytesMapFlag defines a new string to base64 bytes map flag.

func NewStringBoolMapFlag

func NewStringBoolMapFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewStringBoolMapFlag defines a new flag that holds a map of string to bool.

func NewStringBytesMapFlag

func NewStringBytesMapFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewStringBytesMapFlag defines a new string to bytes map flag.

func NewStringDurationMapFlag

func NewStringDurationMapFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewStringDurationMapFlag defines a new flag with string to duration map value.

func NewStringFlag

func NewStringFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewStringFlag defines a new flag with string value.

func NewStringFloat32MapFlag

func NewStringFloat32MapFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewStringFloat32MapFlag defines a new flag that holds a map of string to float32.

func NewStringFloat64MapFlag

func NewStringFloat64MapFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewStringFloat64MapFlag defines a new flag that holds a map of string to float64.

func NewStringHexBytesMapFlag

func NewStringHexBytesMapFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewStringHexBytesMapFlag defines a new string to hex bytes map flag.

func NewStringInt32MapFlag

func NewStringInt32MapFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewStringInt32MapFlag defines a new flag that holds a map of string to int32.

func NewStringInt64MapFlag

func NewStringInt64MapFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewStringInt64MapFlag defines a new flag that holds a map of string to int64.

func NewStringSliceFlag

func NewStringSliceFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewStringSliceFlag defines a new flag that holds a slice of strings.

func NewStringStringMapFlag

func NewStringStringMapFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewStringStringMapFlag defines a new flag that holds a map of string to string.

func NewStringTimestampMapFlag

func NewStringTimestampMapFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewStringTimestampMapFlag defines a new flag that holds a map of string to time.

func NewStringUint32MapFlag

func NewStringUint32MapFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewStringUint32MapFlag defines a new flag that holds a map of string to uint32.

func NewStringUint64MapFlag

func NewStringUint64MapFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewStringUint64MapFlag defines a new flag that holds a map of string to uint64.

func NewTimestampFlag

func NewTimestampFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewTimestampFlag defines a new flag with time value.

func NewTimestampSliceFlag

func NewTimestampSliceFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewTimestampSliceFlag defines a new flag that holds a slice of time values.

func NewUint32Flag

func NewUint32Flag(name, usage string, opts ...FlagOption) *pflag.Flag

NewUint32Flag defines a new flag with uint32 value.

func NewUint32SliceFlag

func NewUint32SliceFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewUint32SliceFlag defines a new flag that holds a slice of uint32 values.

func NewUint64Flag

func NewUint64Flag(name, usage string, opts ...FlagOption) *pflag.Flag

NewUint64Flag defines a new flag with uint64 value.

func NewUint64SliceFlag

func NewUint64SliceFlag(name, usage string, opts ...FlagOption) *pflag.Flag

NewUint64SliceFlag defines a new flag that holds a slice of uint64 values.

func Prefix

func Prefix(field, prefix string) string

Prefix returns a field name with prefix of the form {prefix}.{field}.

func SelectDesc

func SelectDesc(fieldName string, withSubFields bool) string

SelectDesc returns a string with a description for select flags.

func SetEnumString

func SetEnumString(v string, valueMaps ...map[string]int32) (int32, error)

SetEnumString parses an enum from its string flag representation using the value maps. If none of the value maps contains a mapping for the string value, it attempts to parse the string as a numeric value.

func SplitSliceElements

func SplitSliceElements(s string) ([]string, error)

SplitSliceElements returns a slice of strings from a single string with commas.

Types

type AliasValue

type AliasValue struct {
	// contains filtered or unexported fields
}

AliasValue holds a pointer to the target flag.

func (*AliasValue) Set

func (av *AliasValue) Set(s string) error

Set implements pflag.Value interface.

func (*AliasValue) String

func (av *AliasValue) String() string

String implements pflag.Value interface.

func (*AliasValue) Type

func (av *AliasValue) Type() string

Type implements pflag.Value interface.

type BoolSliceValue

type BoolSliceValue struct {
	Values []BoolValue
}

BoolSliceValue implements pflag.Value interface.

func (*BoolSliceValue) Set

func (bsv *BoolSliceValue) Set(s string) error

Set implements pflag.Value interface.

func (*BoolSliceValue) String

func (bsv *BoolSliceValue) String() string

String implements pflag.Value interface.

func (*BoolSliceValue) Type

func (*BoolSliceValue) Type() string

Type implements pflag.Value interface.

type BoolValue

type BoolValue struct {
	Value bool
}

BoolValue implements pflag.Value interface.

func (*BoolValue) Set

func (bv *BoolValue) Set(s string) error

Set implements pflag.Value interface

func (*BoolValue) String

func (bv *BoolValue) String() string

String implements pflag.Value interface.

func (*BoolValue) Type

func (*BoolValue) Type() string

Type implements pflag.Value interface.

type BytesSliceValue

type BytesSliceValue struct {
	Encoding string
	Values   []BytesValue
}

BytesSliceValue implements pflag.Value interface.

func (*BytesSliceValue) Set

func (bsv *BytesSliceValue) Set(s string) error

Set implements pflag.Value interface.

func (*BytesSliceValue) String

func (bsv *BytesSliceValue) String() string

String implements pflag.Value interface.

func (*BytesSliceValue) Type

func (bsv *BytesSliceValue) Type() string

Type implements pflag.Value interface.

type BytesValue

type BytesValue struct {
	Encoding string
	Value    []byte
}

BytesValue implements pflag.Value interface.

func (*BytesValue) Set

func (bv *BytesValue) Set(s string) error

Set implements pflag.Value interface.

func (*BytesValue) String

func (bv *BytesValue) String() string

String implements pflag.Value interface.

func (*BytesValue) Type

func (bv *BytesValue) Type() string

Type implements pflag.Value interface.

type DurationSliceValue

type DurationSliceValue struct {
	Values []DurationValue
}

DurationSliceValue implements pflag.Value interface.

func (*DurationSliceValue) Set

func (dsv *DurationSliceValue) Set(s string) error

Set implements pflag.Value interface

func (*DurationSliceValue) String

func (dsv *DurationSliceValue) String() string

func (*DurationSliceValue) Type

func (*DurationSliceValue) Type() string

Type implements pflag.Value interface.

type DurationValue

type DurationValue struct {
	Value time.Duration
}

DurationValue implements pflag.Value interface.

func (*DurationValue) Set

func (dv *DurationValue) Set(s string) error

Set implements pflag.Value interface

func (*DurationValue) String

func (dv *DurationValue) String() string

String implements pflag.Value interface.

func (*DurationValue) Type

func (*DurationValue) Type() string

Type implements pflag.Value interface.

type ErrFlagNotFound

type ErrFlagNotFound struct {
	FlagName string
}

ErrFlagNotFound defines error on flagset.Lookup with unknown flag name.

func (*ErrFlagNotFound) Error

func (err *ErrFlagNotFound) Error() string

type FlagOption

type FlagOption func(*pflag.Flag)

FlagOption defines a function that operates on a flag object.

func WithHidden

func WithHidden(hidden bool) FlagOption

WithHidden hides flag from help description.

type Float32SliceValue

type Float32SliceValue struct {
	Values []Float32Value
}

Float32SliceValue implements pflag.Value interface.

func (*Float32SliceValue) Set

func (fsv *Float32SliceValue) Set(s string) error

Set implements pflag.Value interface.

func (*Float32SliceValue) String

func (fsv *Float32SliceValue) String() string

String implements pflag.Value interface.

func (*Float32SliceValue) Type

func (*Float32SliceValue) Type() string

Type implements pflag.Value interface.

type Float32Value

type Float32Value struct {
	Value float32
}

Float32Value implements pflag.Value interface.

func (*Float32Value) Set

func (fv *Float32Value) Set(s string) error

Set implements pflag.Value interface

func (*Float32Value) String

func (fv *Float32Value) String() string

String implements pflag.Value interface.

func (*Float32Value) Type

func (*Float32Value) Type() string

Type implements pflag.Value interface.

type Float64SliceValue

type Float64SliceValue struct {
	Values []Float64Value
}

Float64SliceValue implements pflag.Value interface.

func (*Float64SliceValue) Set

func (fsv *Float64SliceValue) Set(s string) error

Set implements pflag.Value interface.

func (*Float64SliceValue) String

func (fsv *Float64SliceValue) String() string

String implements pflag.Value interface.

func (*Float64SliceValue) Type

func (*Float64SliceValue) Type() string

Type implements pflag.Value interface.

type Float64Value

type Float64Value struct {
	Value float64
}

Float64Value implements pflag.Value interface.

func (*Float64Value) Set

func (fv *Float64Value) Set(s string) error

Set implements pflag.Value interface

func (*Float64Value) String

func (fv *Float64Value) String() string

String implements pflag.Value interface.

func (*Float64Value) Type

func (*Float64Value) Type() string

Type implements pflag.Value interface.

type Int32SliceValue

type Int32SliceValue struct {
	Values []Int32Value
}

Int32SliceValue implements pflag.Value interface.

func (*Int32SliceValue) Set

func (isv *Int32SliceValue) Set(s string) error

Set implements pflag.Value interface.

func (*Int32SliceValue) String

func (isv *Int32SliceValue) String() string

String implements pflag.Value interface.

func (*Int32SliceValue) Type

func (*Int32SliceValue) Type() string

Type implements pflag.Value interface.

type Int32Value

type Int32Value struct {
	Value int32
}

Int32Value implements pflag.Value interface.

func (*Int32Value) Set

func (iv *Int32Value) Set(s string) error

Set implements pflag.Value interface

func (*Int32Value) String

func (iv *Int32Value) String() string

String implements pflag.Value interface.

func (*Int32Value) Type

func (*Int32Value) Type() string

Type implements pflag.Value interface.

type Int64SliceValue

type Int64SliceValue struct {
	Values []Int64Value
}

Int64SliceValue implements pflag.Value interface.

func (*Int64SliceValue) Set

func (isv *Int64SliceValue) Set(s string) error

Set implements pflag.Value interface.

func (*Int64SliceValue) String

func (isv *Int64SliceValue) String() string

String implements pflag.Value interface.

func (*Int64SliceValue) Type

func (*Int64SliceValue) Type() string

Type implements pflag.Value interface.

type Int64Value

type Int64Value struct {
	Value int64
}

Int64Value implements pflag.Value interface.

func (*Int64Value) Set

func (iv *Int64Value) Set(s string) error

Set implements pflag.Value interface

func (*Int64Value) String

func (iv *Int64Value) String() string

String implements pflag.Value interface.

func (*Int64Value) Type

func (*Int64Value) Type() string

Type implements pflag.Value interface.

type SetterFromFlags

type SetterFromFlags interface {
	SetFromFlags(flags *pflag.FlagSet, prefix string) (paths []string, err error)
}

SetterFromFlags defines interface for setting proto struct fields from flags.

type StringBoolMapValue

type StringBoolMapValue struct {
	Values map[string]BoolValue
}

StringBoolMapValue implements pflag.Value interface.

func (*StringBoolMapValue) Set

func (sbmv *StringBoolMapValue) Set(s string) error

Set implements pflag.Value interface.

func (*StringBoolMapValue) String

func (sbmv *StringBoolMapValue) String() string

String implements pflag.Value interface.

func (*StringBoolMapValue) Type

func (*StringBoolMapValue) Type() string

Type implements pflag.Value interface.

type StringBytesMapValue

type StringBytesMapValue struct {
	Encoding string
	Values   map[string]BytesValue
}

StringBytesMapValue implements pflag.Value interface.

func (*StringBytesMapValue) Set

func (sbmv *StringBytesMapValue) Set(s string) error

Set implements pflag.Value interface.

func (*StringBytesMapValue) String

func (sbmv *StringBytesMapValue) String() string

String implements pflag.Value interface.

func (*StringBytesMapValue) Type

func (sbmv *StringBytesMapValue) Type() string

Type implements pflag.Value interface.

type StringDurationMapValue

type StringDurationMapValue struct {
	Values map[string]DurationValue
}

StringDurationMapValue implements pflag.Value interface.

func (*StringDurationMapValue) Set

func (sdmv *StringDurationMapValue) Set(s string) error

Set implements pflag.Value interface

func (*StringDurationMapValue) String

func (sdmv *StringDurationMapValue) String() string

String implements pflag.Value interface.

func (*StringDurationMapValue) Type

Type implements pflag.Value interface.

type StringFloat32MapValue

type StringFloat32MapValue struct {
	Values map[string]Float32Value
}

StringFloat32MapValue implements pflag.Value interface.

func (*StringFloat32MapValue) Set

func (sfmv *StringFloat32MapValue) Set(s string) error

Set implements pflag.Value interface.

func (*StringFloat32MapValue) String

func (sfmv *StringFloat32MapValue) String() string

String implements pflag.Value interface.

func (*StringFloat32MapValue) Type

func (*StringFloat32MapValue) Type() string

Type implements pflag.Value interface.

type StringFloat64MapValue

type StringFloat64MapValue struct {
	Values map[string]Float64Value
}

StringFloat64MapValue implements pflag.Value interface.

func (*StringFloat64MapValue) Set

func (sfmv *StringFloat64MapValue) Set(s string) error

Set implements pflag.Value interface.

func (*StringFloat64MapValue) String

func (sfmv *StringFloat64MapValue) String() string

String implements pflag.Value interface.

func (*StringFloat64MapValue) Type

func (*StringFloat64MapValue) Type() string

Type implements pflag.Value interface.

type StringInt32MapValue

type StringInt32MapValue struct {
	Values map[string]Int32Value
}

StringInt32MapValue implements pflag.Value interface.

func (*StringInt32MapValue) Set

func (simv *StringInt32MapValue) Set(s string) error

Set implements pflag.Value interface.

func (*StringInt32MapValue) String

func (simv *StringInt32MapValue) String() string

String implements pflag.Value interface.

func (*StringInt32MapValue) Type

func (*StringInt32MapValue) Type() string

Type implements pflag.Value interface.

type StringInt64MapValue

type StringInt64MapValue struct {
	Values map[string]Int64Value
}

StringInt64MapValue implements pflag.Value interface.

func (*StringInt64MapValue) Set

func (simv *StringInt64MapValue) Set(s string) error

Set implements pflag.Value interface.

func (*StringInt64MapValue) String

func (simv *StringInt64MapValue) String() string

String implements pflag.Value interface.

func (*StringInt64MapValue) Type

func (*StringInt64MapValue) Type() string

Type implements pflag.Value interface.

type StringSliceValue

type StringSliceValue struct {
	Values []StringValue
}

StringSliceValue implements pflag.Value interface.

func (*StringSliceValue) Set

func (ssv *StringSliceValue) Set(s string) error

Set implements pflag.Value interface.

func (*StringSliceValue) String

func (ssv *StringSliceValue) String() string

String implements pflag.Value interface.

func (*StringSliceValue) Type

func (*StringSliceValue) Type() string

Type implements pflag.Value interface.

type StringStringMapValue

type StringStringMapValue struct {
	Values map[string]StringValue
}

StringStringMapValue implements pflag.Value interface.

func (*StringStringMapValue) Set

func (ssmv *StringStringMapValue) Set(s string) error

Set implements pflag.Value interface.

func (*StringStringMapValue) String

func (ssmv *StringStringMapValue) String() string

String implements pflag.Value interface.

func (*StringStringMapValue) Type

func (*StringStringMapValue) Type() string

Type implements pflag.Value interface.

type StringTimestampMapValue

type StringTimestampMapValue struct {
	Values map[string]TimestampValue
}

StringTimestampMapValue implements pflag.Value interface.

func (*StringTimestampMapValue) Set

func (stmv *StringTimestampMapValue) Set(s string) error

Set implements pflag.Value interface.

func (*StringTimestampMapValue) String

func (stmv *StringTimestampMapValue) String() string

String implements pflag.Value interface.

func (*StringTimestampMapValue) Type

Type implements pflag.Value interface.

type StringUint32MapValue

type StringUint32MapValue struct {
	Values map[string]Uint32Value
}

StringUint32MapValue implements pflag.Value interface.

func (*StringUint32MapValue) Set

func (sumv *StringUint32MapValue) Set(s string) error

Set implements pflag.Value interface.

func (*StringUint32MapValue) String

func (sumv *StringUint32MapValue) String() string

String implements pflag.Value interface.

func (*StringUint32MapValue) Type

func (*StringUint32MapValue) Type() string

Type implements pflag.Value interface.

type StringUint64MapValue

type StringUint64MapValue struct {
	Values map[string]Uint64Value
}

StringUint64MapValue implements pflag.Value interface.

func (*StringUint64MapValue) Set

func (sumv *StringUint64MapValue) Set(s string) error

Set implements pflag.Value interface.

func (*StringUint64MapValue) String

func (sumv *StringUint64MapValue) String() string

String implements pflag.Value interface.

func (*StringUint64MapValue) Type

func (*StringUint64MapValue) Type() string

Type implements pflag.Value interface.

type StringValue

type StringValue struct {
	Value string
}

StringValue implements pflag.Value interface.

func (*StringValue) Set

func (sv *StringValue) Set(s string) error

Set implements pflag.Value interface

func (*StringValue) String

func (sv *StringValue) String() string

String implements pflag.Value interface.

func (*StringValue) Type

func (*StringValue) Type() string

Type implements pflag.Value interface.

type TimestampSliceValue

type TimestampSliceValue struct {
	Values []TimestampValue
}

TimestampSliceValue implements pflag.Value interface.

func (*TimestampSliceValue) Set

func (tsv *TimestampSliceValue) Set(s string) error

Set implements pflag.Value interface.

func (*TimestampSliceValue) String

func (tsv *TimestampSliceValue) String() string

String implements pflag.Value interface.

func (*TimestampSliceValue) Type

func (*TimestampSliceValue) Type() string

Type implements pflag.Value interface.

type TimestampValue

type TimestampValue struct {
	Value time.Time
}

TimestampValue implements pflag.Value interface.

func (*TimestampValue) Set

func (tv *TimestampValue) Set(s string) error

Set implements pflag.Value interface

func (*TimestampValue) String

func (tv *TimestampValue) String() string

String implements pflag.Value interface.

func (*TimestampValue) Type

func (*TimestampValue) Type() string

Type implements pflag.Value interface.

type Uint32SliceValue

type Uint32SliceValue struct {
	Values []Uint32Value
}

Uint32SliceValue implements pflag.Value interface.

func (*Uint32SliceValue) Set

func (usv *Uint32SliceValue) Set(s string) error

Set implements pflag.Value interface.

func (*Uint32SliceValue) String

func (usv *Uint32SliceValue) String() string

String implements pflag.Value interface.

func (*Uint32SliceValue) Type

func (*Uint32SliceValue) Type() string

Type implements pflag.Value interface.

type Uint32Value

type Uint32Value struct {
	Value uint32
}

Uint32Value implements pflag.Value interface.

func (*Uint32Value) Set

func (uv *Uint32Value) Set(s string) error

Set implements pflag.Value interface

func (*Uint32Value) String

func (uv *Uint32Value) String() string

String implements pflag.Value interface.

func (*Uint32Value) Type

func (*Uint32Value) Type() string

Type implements pflag.Value interface.

type Uint64SliceValue

type Uint64SliceValue struct {
	Values []Uint64Value
}

Uint64SliceValue implements pflag.Value interface.

func (*Uint64SliceValue) Set

func (usv *Uint64SliceValue) Set(s string) error

Set implements pflag.Value interface.

func (*Uint64SliceValue) String

func (usv *Uint64SliceValue) String() string

String implements pflag.Value interface.

func (*Uint64SliceValue) Type

func (*Uint64SliceValue) Type() string

Type implements pflag.Value interface.

type Uint64Value

type Uint64Value struct {
	Value uint64
}

Uint64Value implements pflag.Value interface.

func (*Uint64Value) Set

func (uv *Uint64Value) Set(s string) error

Set implements pflag.Value interface

func (*Uint64Value) String

func (uv *Uint64Value) String() string

String implements pflag.Value interface.

func (*Uint64Value) Type

func (*Uint64Value) Type() string

Type implements pflag.Value interface.

Jump to

Keyboard shortcuts

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