arg

package
v2.0.0-alpha.65 Latest Latest
Warning

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

Go to latest
Published: Aug 30, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Get

func Get[T argTypes](as *Args, name string) T

func GetCSV

func GetCSV[T argTypes](as *Args, name string) ([]T, error)

func GetContext

func GetContext[T any](as *Args, name string) T

func Gets

func Gets[T argTypes](as *Args, name string) []T

Types

type Args

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

func (*Args) Add

func (as *Args) Add(key string, val any)

func (*Args) AddFinalizer

func (as *Args) AddFinalizer(f func(*Args))

func (Args) Context

func (as Args) Context(key string) any

func (*Args) Del

func (as *Args) Del(key string)

func (Args) Finalizers

func (as Args) Finalizers() []func(*Args)

func (Args) Has

func (as Args) Has(key string) bool

func (Args) HasContext

func (as Args) HasContext(key string) bool

func (*Args) Init

func (as *Args) Init()

func (Args) Keys

func (as Args) Keys() []string

func (Args) Localizer

func (as Args) Localizer() *message.Printer

func (*Args) Set

func (as *Args) Set(key string, val ...any)

func (Args) Value

func (as Args) Value(key string) any

func (Args) Values

func (as Args) Values(key string) []any

func (*Args) WithContext

func (as *Args) WithContext(key string, val any) *Args

func (*Args) WithLocalizer

func (as *Args) WithLocalizer(mp *message.Printer) *Args

Jump to

Keyboard shortcuts

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