meta

package
v1.202.3 Latest Latest
Warning

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

Go to latest
Published: May 24, 2024 License: MIT Imports: 4 Imported by: 17

Documentation

Index

Constants

This section is empty.

Variables

View Source
var NoneConverter = func(s string) string { return s }

NoneConverter for meta.

Functions

func CamelStrings added in v1.160.0

func CamelStrings(ctx context.Context, prefix string) map[string]string

CamelStrings for meta.

func IsBlank added in v1.145.0

func IsBlank(actual Valuer) bool

IsBlank checks for an empty string.

func IsEqual added in v1.145.0

func IsEqual(actual Valuer, expected string) bool

IsEqual checks if actual is expected.

func SnakeStrings added in v1.160.0

func SnakeStrings(ctx context.Context, prefix string) map[string]string

SnakeStrings for meta.

func Strings added in v1.145.0

func Strings(ctx context.Context, prefix string, converter Converter) map[string]string

Strings for meta.

func ValueOrBlank added in v1.146.0

func ValueOrBlank(s Valuer) string

ValueOrBlank for meta.

func WithAttribute

func WithAttribute(ctx context.Context, key string, value Valuer) context.Context

WithAttribute to meta.

Types

type Converter added in v1.160.0

type Converter func(string) string

Converter for meta.

type Redacted added in v1.145.2

type Redacted string

Redacted for meta.

func ToRedacted added in v1.168.0

func ToRedacted(st fmt.Stringer) Redacted

ToRedacted for meta.

func (Redacted) String added in v1.145.2

func (v Redacted) String() string

String to satisfy fmt.Stringer.

func (Redacted) Value added in v1.146.0

func (v Redacted) Value() string

Value of the string.

type String added in v1.145.2

type String string

String for meta.

func ToString added in v1.168.0

func ToString(st fmt.Stringer) String

ToString for meta.

func (String) String added in v1.145.2

func (v String) String() string

String to satisfy fmt.Stringer.

func (String) Value added in v1.146.0

func (v String) Value() string

Value of the string.

type Valuer added in v1.146.0

type Valuer interface {
	Value() string

	fmt.Stringer
}

Valuer for meta.

func Attribute

func Attribute(ctx context.Context, key string) Valuer

Attribute of meta.

func Error added in v1.145.2

func Error(err error) Valuer

Error for meta.

Jump to

Keyboard shortcuts

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