class RoutingResolverPass
Adds tagged routing.loader services to routing.resolver service.
@author Fabien Potencier <fabien@symfony.com>
Hierarchy
- class \Symfony\Component\Routing\DependencyInjection\RoutingResolverPass implements \Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface uses \Symfony\Component\DependencyInjection\Compiler\PriorityTaggedServiceTrait
Expanded class hierarchy of RoutingResolverPass
File
-
vendor/
symfony/ routing/ DependencyInjection/ RoutingResolverPass.php, line 24
Namespace
Symfony\Component\Routing\DependencyInjectionView source
class RoutingResolverPass implements CompilerPassInterface {
use PriorityTaggedServiceTrait;
public function process(ContainerBuilder $container) : void {
if (false === $container->hasDefinition('routing.resolver')) {
return;
}
$definition = $container->getDefinition('routing.resolver');
foreach ($this->findAndSortTaggedServices('routing.loader', $container) as $id) {
$definition->addMethodCall('addLoader', [
new Reference($id),
]);
}
}
}
Members
Title Sort descending | Modifiers | Object type | Summary | Overriden Title |
---|---|---|---|---|
PriorityTaggedServiceTrait::findAndSortTaggedServices | private | function | Finds all services with the given tag name and order them by their priority. | |
RoutingResolverPass::process | public | function | You can modify the container here before it is dumped to PHP code. | Overrides CompilerPassInterface::process |