class Athena::HTTP::RequestMatcher
inherits Reference
#
Verifies that all checks match against an AHTTP::Request instance.
matcher = AHTTP::RequestMatcher.new(
AHTTP::RequestMatcher::Path.new(%r(/admin/foo)),
AHTTP::RequestMatcher::Method.new("GET"),
)
matcher.matches?(AHTTP::Request.new "GET", "/admin/foo") # => true
matcher.matches?(AHTTP::Request.new "POST", "/admin/foo") # => false
Included modules
Athena::HTTP::RequestMatcher::Interface
Constructors#
Methods#
#matches?(request : AHTTP::Request) : Bool#
Decides whether the rule(s) implemented by the strategy matches the provided request.