function UrlMatcher::match
Overrides UrlMatcherInterface::match
5 calls to UrlMatcher::match()
- RedirectableUrlMatcher::match in vendor/
symfony/ routing/ Matcher/ RedirectableUrlMatcher.php - Tries to match a URL path with a set of routes.
- RedirectableUrlMatcher::match in vendor/
symfony/ routing/ Matcher/ RedirectableUrlMatcher.php - Tries to match a URL path with a set of routes.
- TraceableUrlMatcher::getTraces in vendor/
symfony/ routing/ Matcher/ TraceableUrlMatcher.php - UrlMatcher::finalMatch in core/
lib/ Drupal/ Core/ Routing/ UrlMatcher.php - UrlMatcher::matchRequest in vendor/
symfony/ routing/ Matcher/ UrlMatcher.php - Tries to match a request with a set of routes.
2 methods override UrlMatcher::match()
- RedirectableUrlMatcher::match in vendor/
symfony/ routing/ Matcher/ RedirectableUrlMatcher.php - Tries to match a URL path with a set of routes.
- Router::match in core/
lib/ Drupal/ Core/ Routing/ Router.php - Tries to match a URL path with a set of routes.
File
-
vendor/
symfony/ routing/ Matcher/ UrlMatcher.php, line 70
Class
- UrlMatcher
- UrlMatcher matches URL based on a set of routes.
Namespace
Symfony\Component\Routing\MatcherCode
public function match(string $pathinfo) : array {
$this->allow = $this->allowSchemes = [];
if ($ret = $this->matchCollection(rawurldecode($pathinfo) ?: '/', $this->routes)) {
return $ret;
}
if ('/' === $pathinfo && !$this->allow && !$this->allowSchemes) {
throw new NoConfigurationException();
}
throw 0 < \count($this->allow) ? new MethodNotAllowedException(array_unique($this->allow)) : new ResourceNotFoundException(\sprintf('No routes found for "%s".', $pathinfo));
}