class PathRequestMatcher
Checks the Request URL path info matches a regular expression.
@author Fabien Potencier <fabien@symfony.com>
Hierarchy
- class \Symfony\Component\HttpFoundation\RequestMatcher\PathRequestMatcher implements \Symfony\Component\HttpFoundation\RequestMatcherInterface
Expanded class hierarchy of PathRequestMatcher
File
-
vendor/
symfony/ http-foundation/ RequestMatcher/ PathRequestMatcher.php, line 22
Namespace
Symfony\Component\HttpFoundation\RequestMatcherView source
class PathRequestMatcher implements RequestMatcherInterface {
public function __construct(string $regexp) {
}
public function matches(Request $request) : bool {
return preg_match('{' . $this->regexp . '}', rawurldecode($request->getPathInfo()));
}
}
Members
Title Sort descending | Modifiers | Object type | Summary | Overriden Title |
---|---|---|---|---|
PathRequestMatcher::matches | public | function | Decides whether the rule(s) implemented by the strategy matches the supplied request. | Overrides RequestMatcherInterface::matches |
PathRequestMatcher::__construct | public | function |