Documentation ¶
Overview ¶
Package labels provides storing, fetching and matching based on labels.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AndMatcher ¶
type AndMatcher struct {
Matchers []Matcher
}
AndMatcher is a composite matcher that selects all labels that are selected by all matchers.
func And ¶
func And(ms ...Matcher) AndMatcher
And returns a composite matcher that selects all labels that are selected by all matchers.
func (AndMatcher) Matches ¶
func (s AndMatcher) Matches(labels Labels) bool
Matches returns true if the labels are selected by one of the matchers in the andMatchers.
type InMatcher ¶
InMatcher matches all labels where the label keys equals the key, and (optionally) the value has to be in the set of accepted values.
type Labels ¶
type Labels interface { // Get returns the value for the provided label. Get(label string) (value string, exists bool) }
Labels is the interface for fetching labels.
type OrMatcher ¶
type OrMatcher struct {
// contains filtered or unexported fields
}
OrMatcher is a composite matcher that selects all labels that are selected by one of the matchers.
Click to show internal directories.
Click to hide internal directories.