MCPcopy
hub / github.com/zalando/skipper / Matcher

Interface Matcher

pathmux/tree.go:18–24  ·  view source on GitHub ↗

Matcher objects, when using the LookupMatcher function, can be used for additional checks and to override the default result in case of path matches. The argument passed to the Match function is the original value passed to the Tree.Add function.

Source from the content-addressed store, hash-verified

16// default result in case of path matches. The argument passed to the Match function is the original value
17// passed to the Tree.Add function.
18type Matcher interface {
19
20 // Match should return true and the object to be returned by the lookup, when the argument value fulfils the
21 // conditions defined by the custom logic in the matcher itself. If it returns false, it instructs the
22 // lookup to continue with backtracking from the current tree position.
23 Match(value interface{}) (bool, interface{})
24}
25
26type trueMatcher struct{}
27

Callers 1

searchMethod · 0.65

Implementers 15

nonePredicate_test_plugins_fail/fail.go
falsePredicatepredicates/primitive/false.go
shutdownpredicates/primitive/shutdown.go
truePredicatepredicates/primitive/true.go
headerSha256Predicatepredicates/auth/headersha256.go
exactMatcherpredicates/auth/jwt.go
regexMatcherpredicates/auth/jwt.go
predicatepredicates/auth/jwt.go
AnyPredicatepredicates/host/any.go
predicatepredicates/cron/cron.go
predicatepredicates/source/source.go
predicatepredicates/tee/tee.go

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…