Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Matcher ¶
type Matcher struct { Prefix string `json:"prefix,omitempty"` NotPrefix string `json:"notPrefix,omitempty"` Sub string `json:"sub,omitempty"` NotSub string `json:"notSub,omitempty"` Regex string `json:"regex,omitempty"` NotRegex string `json:"notRegex,omitempty"` // contains filtered or unexported fields }
func (*Matcher) MatchRegexAndExpand ¶ added in v0.13.0
MatchRegexAndExpand only matches the given key against the "regex" condition, if it matches then it applies the given template and returns the resulting string as the first return value. The second return value indicates whether the regex matches the given key.
func (*Matcher) PreMatch ¶ added in v0.13.0
PreMatch only checks the conditions which can be evaluated very quickly, while ignoring the ones which are more expensive to evaluate. If it returns false then a metric can be discarded, if it returns true then Match() should be applied to it to know whether it matches all criterias.
Click to show internal directories.
Click to hide internal directories.