Symfony\Component\Routing\Matcher\UrlMatcher
UrlMatcher matches URL based on a set of routes.
- Author: Fabien Potencier <fabien@symfony.com>
Synopsis
class UrlMatcher
implements
UrlMatcherInterface
{
- // constants
- const REQUIREMENT_MATCH = 0;
- const REQUIREMENT_MISMATCH = 1;
- const ROUTE_MATCH = 2;
- // members
- protected RequestContext $context;
- protected array $allow;
- protected RouteCollection $routes;
- // methods
- public void __construct()
- public void setContext()
- public void getContext()
- public void match()
- protected array matchCollection()
- protected array getAttributes()
- protected array handleRouteRequirements()
- protected array mergeDefaults()
Hierarchy
Extended by
- Symfony\Component\Routing\Matcher\ApacheUrlMatcher
- Symfony\Component\Routing\Matcher\RedirectableUrlMatcher
- Symfony\Component\Routing\Matcher\TraceableUrlMatcher
- Symfony\Bundle\FrameworkBundle\Routing\RedirectableUrlMatcher
Implements
Constants
Name | Value |
---|---|
REQUIREMENT_MATCH | 0 |
REQUIREMENT_MISMATCH | 1 |
ROUTE_MATCH | 2 |
Members
protected
- $allow — array
- $context — Symfony\Component\Routing\RequestContext
- $routes — Symfony\Component\Routing\RouteCollection
Methods
protected
- getAttributes() — Returns an array of values to use as request attributes.
- handleRouteRequirements() — Handles specific route requirements.
- matchCollection() — Tries to match a URL with a set of routes.
- mergeDefaults() — Get merged default parameters.
public
- __construct() — Constructor.
- getContext() — {@inheritdoc}
- match() — {@inheritdoc}
- setContext() — {@inheritdoc}