settings

package
v1.2.4 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ApplyGRPCSettings

func ApplyGRPCSettings(
	opts *grpcx.Options,
	settings map[string]string,
	resolver *vars.Resolver,
) error

func ApplyHTTPSettings

func ApplyHTTPSettings(
	opts *httpx.Options,
	settings map[string]string,
	resolver *vars.Resolver,
) error

func FromValues added in v0.49.1

func FromValues(values map[string]string) map[string]string

func IsHTTPKey added in v0.17.1

func IsHTTPKey(key string) bool

IsHTTPKey reports whether key is a supported HTTP setting key.

func Merge

func Merge(scopes ...map[string]string) map[string]string

Types

type Applier

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

func New

func New(handlers ...Handler) Applier

func (Applier) ApplyAll

func (a Applier) ApplyAll(settings map[string]string) (map[string]string, error)

type ApplyFunc

type ApplyFunc func(key, val string) error

type Handler

type Handler struct {
	Match Matcher
	Apply ApplyFunc
}

func GRPCHandler

func GRPCHandler(opts *grpcx.Options, resolver *vars.Resolver) Handler

func HTTPHandler

func HTTPHandler(opts *httpx.Options, resolver *vars.Resolver) Handler

type Matcher

type Matcher func(string) bool

func PrefixMatcher

func PrefixMatcher(prefixes ...string) Matcher

type ResolverProvider

type ResolverProvider interface {
	Resolver() *vars.Resolver
}

Jump to

Keyboard shortcuts

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