internal

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Aug 21, 2025 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrTrailingGarbage = errors.New("trailing garbage in JSON file")

Functions

func AppName

func AppName() string

AppName is what the app will call itself. When customizing, overwrite it before calling Main().

func CheckCanCustomize

func CheckCanCustomize()

See: [instance.CheckCanCustomize] for details and an importable version of this function.

func CheckLockedDown

func CheckLockedDown()

See: [instance.CheckLockedDown] for details and an importable version of this function.

func FilterSlice

func FilterSlice[E any, S ~[]E](s S, f func(E) bool) S

func IsDebuggerAttached added in v0.5.0

func IsDebuggerAttached() bool

func LockCustomizations

func LockCustomizations()

func Must

func Must[T any](v T, err error) T

func Ptr

func Ptr[T any](t T) *T

func ReadJSONFile

func ReadJSONFile[T any](name string) (T, error)

func SeqContains added in v0.5.0

func SeqContains[T comparable](src iter.Seq[T], v T) bool

func SeqReader added in v0.3.0

func SeqReader(src iter.Seq2[[]byte, error]) io.ReadCloser

SeqReader converts an iterator to an io.ReadCloser

func SetAppName

func SetAppName(name string)

func ValueOrDefault

func ValueOrDefault[T any](p *T, d T) T

func ValueOrZero

func ValueOrZero[T any](p *T) T

Types

type NoCopy added in v0.2.0

type NoCopy struct{}

func (NoCopy) Lock added in v0.2.0

func (NoCopy) Lock()

func (NoCopy) Unlock added in v0.2.0

func (NoCopy) Unlock()

Jump to

Keyboard shortcuts

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