SimpleBusBridgeBundle::load()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 1
1
<?php
2
3
/*
4
 * This file is part of the BenGorUser package.
5
 *
6
 * (c) Beñat Espiña <[email protected]>
7
 * (c) Gorka Laucirica <[email protected]>
8
 *
9
 * For the full copyright and license information, please view the LICENSE
10
 * file that was distributed with this source code.
11
 */
12
13
namespace BenGorUser\SimpleBusBridgeBundle;
14
15
use BenGorUser\SimpleBusBridgeBundle\DependencyInjection\Compiler\SimpleBusPass;
16
use BenGorUser\UserBundle\DependentBenGorUserBundle;
17
use BenGorUser\UserBundle\LoadableBundle;
18
use Symfony\Component\DependencyInjection\Compiler\PassConfig;
19
use Symfony\Component\DependencyInjection\ContainerBuilder;
20
use Symfony\Component\HttpKernel\Bundle\Bundle;
21
22
/**
23
 * Simple bus bridge bundle kernel class.
24
 *
25
 * @author Beñat Espiña <[email protected]>
26
 */
27
class SimpleBusBridgeBundle extends Bundle implements LoadableBundle
28
{
29
    use DependentBenGorUserBundle;
30
31
    /**
32
     * {@inheritdoc}
33
     */
34
    public function build(ContainerBuilder $container)
35
    {
36
        $this->checkDependencies(['BenGorUserBundle'], $container);
37
    }
38
39
    /**
40
     * {@inheritdoc}
41
     */
42
    public function load(ContainerBuilder $container)
43
    {
44
        $container->addCompilerPass(new SimpleBusPass(), PassConfig::TYPE_OPTIMIZE);
45
    }
46
}
47