Documentation ¶
Index ¶
- func BoolPtrValue(val *bool, p **bool) pflag.Value
- func BytesPtrValue(val []byte, p *[]byte) pflag.Value
- func DurationpbSliceValue(val []time.Duration, p *[]*durationpb.Duration) pflag.Value
- func DurationpbValue(val *time.Duration, p **durationpb.Duration) pflag.Value
- func EnumPtrValue[E protoenum[E]](val *E, p **E) pflag.Value
- func EnumValue[E protoenum[E]](val E, p *E) pflag.Value
- func FloatPtrValue[T constraints.Float](val *T, p **T) pflag.Value
- func IPNetSliceValue(val []string, p *[]string) pflag.Value
- func IPNetValue(val string, p *string) pflag.Value
- func IntPtrValue[T constraints.Signed](val *T, p **T) pflag.Value
- func LoadDefaults[T FlagSetter](obj T)
- func ParseDurationWithExtendedUnits(s string) (time.Duration, error)
- func Ptr[T any](t T) *T
- func SetDefValue(fs *pflag.FlagSet, name, value string)
- func StringPtrValue(val *string, p **string) pflag.Value
- func StringToFloat64Value(val map[string]float64, p *map[string]float64) pflag.Value
- func TimestamppbValue(val *string, p **timestamppb.Timestamp) pflag.Value
- func UintPtrValue[T constraints.Unsigned](val *T, p **T) pflag.Value
- type FlagSetter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DurationpbSliceValue ¶
func DurationpbValue ¶
func EnumPtrValue ¶
func FloatPtrValue ¶
func FloatPtrValue[T constraints.Float](val *T, p **T) pflag.Value
func IntPtrValue ¶
func IntPtrValue[T constraints.Signed](val *T, p **T) pflag.Value
func LoadDefaults ¶
func LoadDefaults[T FlagSetter](obj T)
func SetDefValue ¶
Sets DefValue and calls Value.Set for a flag. Must only be used after calling AddFlagSet and before calling Parse.
func StringToFloat64Value ¶
func TimestamppbValue ¶
func TimestamppbValue(val *string, p **timestamppb.Timestamp) pflag.Value
func UintPtrValue ¶
func UintPtrValue[T constraints.Unsigned](val *T, p **T) pflag.Value
Types ¶
type FlagSetter ¶
Click to show internal directories.
Click to hide internal directories.