package method
import "github.com/google/martian/v3/method"
Package method provides utilities for working with request methods.
Index ¶
Functions ¶
func NewVerifier ¶
func NewVerifier(method string) (verify.RequestVerifier, error)
NewVerifier returns a new method verifier.
Types ¶
type Filter ¶
Filter runs modifier iff the request method matches the specified method.
func NewFilter ¶
NewFilter constructs a filter that applies the modifer when the request method matches meth.
type Matcher ¶
type Matcher struct {
// contains filtered or unexported fields
}
Matcher is a conditional evaluator of request methods to be used in filters that take conditionals.
func NewMatcher ¶
NewMatcher builds a new method matcher.
func (*Matcher) MatchRequest ¶
MatchRequest retuns true if m.method matches the request method.
func (*Matcher) MatchResponse ¶
MatchResponse retuns true if m.method matches res.Request.Method.
Source Files ¶
method_filter.go method_verifier.go
- Version
- v3.3.3 (latest)
- Published
- Aug 16, 2022
- Platform
- linux/amd64
- Imports
- 9 packages
- Last checked
- 5 hours ago –
Tools for package owners.