Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Interval ¶
type Interval struct { OldestInclusive clientmodel.Timestamp NewestInclusive clientmodel.Timestamp }
Interval describes the inclusive interval between two Timestamps.
type LabelMatcher ¶
type LabelMatcher struct { Type MatchType Name clientmodel.LabelName Value clientmodel.LabelValue // contains filtered or unexported fields }
LabelMatcher models the matching of a label.
func NewLabelMatcher ¶
func NewLabelMatcher(matchType MatchType, name clientmodel.LabelName, value clientmodel.LabelValue) (*LabelMatcher, error)
NewLabelMatcher returns a LabelMatcher object ready to use.
func (*LabelMatcher) Filter ¶
func (m *LabelMatcher) Filter(in clientmodel.LabelValues) clientmodel.LabelValues
Filter takes a list of label values and returns all label values which match the label matcher.
func (*LabelMatcher) Match ¶
func (m *LabelMatcher) Match(v clientmodel.LabelValue) bool
Match returns true if the label matcher matches the supplied label value.
func (*LabelMatcher) String ¶
func (m *LabelMatcher) String() string
type LabelMatchers ¶
type LabelMatchers []*LabelMatcher
LabelMatchers is a slice of LabelMatcher objects.
type LabelPair ¶
type LabelPair struct { Name clientmodel.LabelName Value clientmodel.LabelValue }
LabelPair pairs a name with a value.
type LabelPairs ¶
type LabelPairs []*LabelPair
LabelPairs is a sortable slice of LabelPair pointers. It implements sort.Interface.
func (LabelPairs) Len ¶
func (l LabelPairs) Len() int
func (LabelPairs) Less ¶
func (l LabelPairs) Less(i, j int) bool
func (LabelPairs) Swap ¶
func (l LabelPairs) Swap(i, j int)
type SamplePair ¶
type SamplePair struct { Timestamp clientmodel.Timestamp Value clientmodel.SampleValue }
SamplePair pairs a SampleValue with a Timestamp.
func (*SamplePair) Equal ¶
func (s *SamplePair) Equal(o *SamplePair) bool
Equal returns true if this SamplePair and o have equal Values and equal Timestamps.
func (SamplePair) MarshalJSON ¶
func (s SamplePair) MarshalJSON() ([]byte, error)
MarshalJSON implements json.Marshaler.
func (*SamplePair) String ¶
func (s *SamplePair) String() string