-
Notifications
You must be signed in to change notification settings - Fork 29
/
AdmingeneratorGeneratorBundle.php
31 lines (25 loc) · 1.13 KB
/
AdmingeneratorGeneratorBundle.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
<?php
namespace Admingenerator\GeneratorBundle;
use Admingenerator\GeneratorBundle\DependencyInjection\AdmingeneratorGeneratorExtension;
use Admingenerator\GeneratorBundle\DependencyInjection\Compiler\RemoveMakerCommandPass;
use Symfony\Component\HttpKernel\Bundle\Bundle;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Admingenerator\GeneratorBundle\DependencyInjection\Compiler\TwigLoaderPass;
use Admingenerator\GeneratorBundle\DependencyInjection\Compiler\ValidatorPass;
use Admingenerator\GeneratorBundle\DependencyInjection\Compiler\FormPass;
class AdmingeneratorGeneratorBundle extends Bundle
{
public function build(ContainerBuilder $container): void
{
parent::build($container);
$container->addCompilerPass(new ValidatorPass());
$container->addCompilerPass(new FormPass());
$container->addCompilerPass(new TwigLoaderPass());
$container->addCompilerPass(new RemoveMakerCommandPass());
}
public function getContainerExtension(): AdmingeneratorGeneratorExtension
{
$this->extension = new AdmingeneratorGeneratorExtension();
return $this->extension;
}
}