pub fn matches_route(
rule: &MatchRule,
path: &str,
method: &str,
headers: &[(String, String)],
host: &str,
) -> boolExpand description
Matches an incoming request against a route’s match rule.
All criteria present in the rule must match (logical AND); absent criteria match anything. Semantics per criterion:
- path — exact match, trailing
/*prefix wildcard, or*path segment wildcards (seematch_path); - methods — case-insensitive; an empty list matches any method;
- headers — every required key must be present with an exactly equal value (header names compared case-insensitively, values exactly);
- host — case-insensitive equality.