vars

package
v0.0.0-...-7899014 Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2024 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNotFound = errors.New("not found")

Functions

func TestVars

func TestVars(
	t *testing.T,
	scope Scope,
	wg *pr2.WaitGroup,
)

Types

type Def

type Def struct{}

func (Def) Get

func (Def) Get(
	store *VarsStore,
) Get

func (Def) Set

func (Def) Set(
	store *VarsStore,
) Set

func (Def) VarsStore

func (Def) VarsStore(
	ensureDir fsys.EnsureDir,
	spec VarsSpec,
	setRestrictedPath fsys.SetRestrictedPath,
) *VarsStore

type Get

type Get func(key string, target any) error

type NotFound

type NotFound struct {
	Key string
}

func (*NotFound) Error

func (n *NotFound) Error() string

type Scope

type Scope = dscope.Scope

type Set

type Set func(key string, value any) error

type VarsSpec

type VarsSpec func() (
	dir string,
	wg *pr2.WaitGroup,
)

type VarsStore

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

Jump to

Keyboard shortcuts

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