expansion

package
v1.9.2 Latest Latest
Warning

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

Go to latest
Published: Apr 2, 2023 License: Apache-2.0, BSD-3-Clause Imports: 1 Imported by: 0

README

Copied from https://github.com/kubernetes/kubernetes/tree/master/third_party/forked/golang/expansion .

This is to eliminate a direct dependency on kubernetes/kubernetes.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Expand

func Expand(input string, mapping func(string) string) string

Expand replaces variable references in the input string according to the expansion spec using the given mapping function to resolve the values of variables.

func MappingFuncFor

func MappingFuncFor(context ...map[string]string) func(string) string

MappingFuncFor returns a mapping function for use with Expand that implements the expansion semantics defined in the expansion spec; it returns the input string wrapped in the expansion syntax if no mapping for the input is found.

Types

This section is empty.

Jump to

Keyboard shortcuts

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