knobs

package
v0.0.247 Latest Latest
Warning

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

Go to latest
Published: Jun 16, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SetupFlags

func SetupFlags(flags *pflag.FlagSet)

Types

type Knob

type Knob[V any] struct {
	// contains filtered or unexported fields
}

func Bool

func Bool(name, description string, value bool) Knob[bool]

func Define

func Define[V any](name, description string, value Value) Knob[V]

func (Knob[V]) Get

func (knob Knob[V]) Get(src cfg.Configuration) V

type Value

type Value interface {
	// contains filtered or unexported methods
}

func BoolValue

func BoolValue[V bool](defaultValue bool) Value

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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