providerresource

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Mar 26, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ApplyEnvDefaults

func ApplyEnvDefaults[C any](
	cfg *C,
	configFromEnv func() *C,
	withDefaults func(*C) *C,
	hasProvider func(*C) bool,
	hasFallbacks func(*C) bool,
	merge func(current, env *C, hasProvider, hasFallbacks bool),
) *C

ApplyEnvDefaults merges environment-derived defaults into a config after the config-specific defaulting has been applied.

func Run

func Run[P registry.Named, R any](
	provider string,
	fallbacks []string,
	defaultFallbackOrder []string,
	register func(*registry.Registry[P]),
	exec func(P) (*R, error),
	decorate func(string, *R),
	noProviderErr error,
) (*R, error)

Run executes a provider chain after registering available providers.

Types

This section is empty.

Jump to

Keyboard shortcuts

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