Verzeichnisstruktur phpBB-3.3.15
- Veröffentlicht
- 28.08.2024
So funktioniert es
|
Auf das letzte Element klicken. Dies geht jeweils ein Schritt zurück |
Auf das Icon klicken, dies öffnet das Verzeichnis. Nochmal klicken schließt das Verzeichnis. |
|
(Beispiel Datei-Icons)
|
Auf das Icon klicken um den Quellcode anzuzeigen |
ControllerArgumentValueResolverPass.php
01 <?php
02
03 /*
04 * This file is part of the Symfony package.
05 *
06 * (c) Fabien Potencier <fabien@symfony.com>
07 *
08 * For the full copyright and license information, please view the LICENSE
09 * file that was distributed with this source code.
10 */
11
12 namespace Symfony\Component\HttpKernel\DependencyInjection;
13
14 use Symfony\Component\DependencyInjection\Argument\IteratorArgument;
15 use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface;
16 use Symfony\Component\DependencyInjection\Compiler\PriorityTaggedServiceTrait;
17 use Symfony\Component\DependencyInjection\ContainerBuilder;
18
19 /**
20 * Gathers and configures the argument value resolvers.
21 *
22 * @author Iltar van der Berg <kjarli@gmail.com>
23 */
24 class ControllerArgumentValueResolverPass implements CompilerPassInterface
25 {
26 use PriorityTaggedServiceTrait;
27
28 private $argumentResolverService;
29 private $argumentValueResolverTag;
30
31 public function __construct($argumentResolverService = 'argument_resolver', $argumentValueResolverTag = 'controller.argument_value_resolver')
32 {
33 $this->argumentResolverService = $argumentResolverService;
34 $this->argumentValueResolverTag = $argumentValueResolverTag;
35 }
36
37 public function process(ContainerBuilder $container)
38 {
39 if (!$container->hasDefinition($this->argumentResolverService)) {
40 return;
41 }
42
43 $container
44 ->getDefinition($this->argumentResolverService)
45 ->replaceArgument(1, new IteratorArgument($this->findAndSortTaggedServices($this->argumentValueResolverTag, $container)))
46 ;
47 }
48 }
49