public function ContainerBuilder::addCompilerPass in Zircon Profile 8.0
Same name and namespace in other branches
- 8 vendor/symfony/dependency-injection/ContainerBuilder.php \Symfony\Component\DependencyInjection\ContainerBuilder::addCompilerPass()
Adds a compiler pass.
Parameters
CompilerPassInterface $pass A compiler pass:
string $type The type of compiler pass:
Return value
ContainerBuilder The current instance
File
- vendor/
symfony/ dependency-injection/ ContainerBuilder.php, line 296
Class
- ContainerBuilder
- ContainerBuilder is a DI container that provides an API to easily describe services.
Namespace
Symfony\Component\DependencyInjectionCode
public function addCompilerPass(CompilerPassInterface $pass, $type = PassConfig::TYPE_BEFORE_OPTIMIZATION) {
$this
->getCompiler()
->addPass($pass, $type);
$this
->addObjectResource($pass);
return $this;
}