labels

package
v0.0.13 Latest Latest
Warning

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

Go to latest
Published: Jan 22, 2026 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultLabelPrefix = "voiyd.io"

Variables

View Source
var DefaultContainerLabels = []string{LabelPrefix("uuid").String()}

Functions

This section is empty.

Types

type CompositeSelector

type CompositeSelector struct {
	Selectors []Selector
}

func NewCompositeSelectorFromMap

func NewCompositeSelectorFromMap(labelMap map[string]string) CompositeSelector

func (CompositeSelector) Matches

func (s CompositeSelector) Matches(labels Label) bool

type EqualitySelector

type EqualitySelector struct {
	Key   string
	Value string
}

func (EqualitySelector) Matches

func (s EqualitySelector) Matches(labels Label) bool

type ExistsSelector

type ExistsSelector struct {
	Key string
}

func (ExistsSelector) Matches

func (s ExistsSelector) Matches(labels Label) bool

type Label

type Label map[string]string

Label is a map representing metadata of each resource.

func New

func New() Label

func (*Label) AppendMap

func (l *Label) AppendMap(m map[string]string)

func (*Label) Delete

func (l *Label) Delete(key string)

func (*Label) Get

func (l *Label) Get(key string) string

func (*Label) Set

func (l *Label) Set(key string, value string)

type LabelPrefix

type LabelPrefix string

func (LabelPrefix) String

func (d LabelPrefix) String() string

type Selector

type Selector interface {
	Matches(labels Label) bool
}

type SetSelector

type SetSelector struct {
	Key    string
	Values []string
	In     bool // true for "in", false for "notin"
}

func (SetSelector) Matches

func (s SetSelector) Matches(labels Label) bool

Jump to

Keyboard shortcuts

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