1 | <?php |
||
2 | |||
3 | /* |
||
4 | * This file is part of the FacadeBundle |
||
5 | * |
||
6 | * (c) Indra Gunawan <[email protected]> |
||
7 | * |
||
8 | * For the full copyright and license information, please view the LICENSE |
||
9 | * file that was distributed with this source code. |
||
10 | */ |
||
11 | |||
12 | namespace Indragunawan\FacadeBundle; |
||
13 | |||
14 | use Indragunawan\FacadeBundle\DependencyInjection\Compiler\AddFacadePass; |
||
15 | use Symfony\Component\DependencyInjection\ContainerBuilder; |
||
16 | use Symfony\Component\HttpKernel\Bundle\Bundle; |
||
17 | |||
18 | /** |
||
19 | * @author Indra Gunawan <[email protected]> |
||
20 | */ |
||
21 | final class IndragunawanFacadeBundle extends Bundle |
||
22 | { |
||
23 | /** |
||
24 | * {@inheritdoc} |
||
25 | */ |
||
26 | 1 | public function boot() |
|
27 | { |
||
28 | 1 | parent::boot(); |
|
29 | |||
30 | 1 | AbstractFacade::setFacadeContainer($this->container->get('indragunawan.facade.container')); |
|
31 | 1 | } |
|
32 | |||
33 | /** |
||
34 | * {@inheritdoc} |
||
35 | */ |
||
36 | 1 | public function build(ContainerBuilder $container) |
|
37 | { |
||
38 | 1 | parent::build($container); |
|
39 | |||
40 | 1 | $container->addCompilerPass(new AddFacadePass()); |
|
41 | 1 | } |
|
42 | } |
||
43 |