You are here

protected function DynamicRouter::applyRouteEnhancers in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/symfony-cmf/routing/DynamicRouter.php \Symfony\Cmf\Component\Routing\DynamicRouter::applyRouteEnhancers()

Apply the route enhancers to the defaults, according to priorities

Parameters

array $defaults:

Request $request:

Return value

array

2 calls to DynamicRouter::applyRouteEnhancers()
DynamicRouter::match in vendor/symfony-cmf/routing/DynamicRouter.php
Tries to match a URL path with a set of routes.
DynamicRouter::matchRequest in vendor/symfony-cmf/routing/DynamicRouter.php
Tries to match a request with a set of routes and returns the array of information for that route.

File

vendor/symfony-cmf/routing/DynamicRouter.php, line 272

Class

DynamicRouter
A flexible router accepting matcher and generator through injection and using the RouteEnhancer concept to generate additional data on the routes.

Namespace

Symfony\Cmf\Component\Routing

Code

protected function applyRouteEnhancers($defaults, Request $request) {
  foreach ($this
    ->getRouteEnhancers() as $enhancer) {
    $defaults = $enhancer
      ->enhance($defaults, $request);
  }
  return $defaults;
}