Completed
Push — master ( 57a73d...51c7de )
by Alexey
38:40
created

SfCodSocketIoBundle::build()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 6

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 6
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 1
1
<?php
2
3
namespace SfCod\SocketIoBundle;
4
5
use SfCod\QueueBundle\DependencyInjection\Compiler\JobCompilerPass;
6
use SfCod\SocketIoBundle\DependencyInjection\Compiler\EventCompilerPass;
7
use SfCod\SocketIoBundle\DependencyInjection\SocketIoExtension;
8
use Symfony\Component\DependencyInjection\ContainerBuilder;
9
use Symfony\Component\HttpKernel\Bundle\Bundle;
10
11
/**
12
 * Class SfCodSocketIoBundle
13
 *
14
 * @author Virchenko Maksim <[email protected]>
15
 *
16
 * @package SfCod\SocketIoBundle
17
 */
18
class SfCodSocketIoBundle extends Bundle
19
{
20
    /**
21
     * Get bundle extension
22
     *
23
     * @return null|SocketIoExtension|\Symfony\Component\DependencyInjection\Extension\ExtensionInterface
24
     */
25
    public function getContainerExtension()
26
    {
27
        return new SocketIoExtension();
28
    }
29
30
    /**
31
     * Add compiler pass
32
     *
33
     * @param ContainerBuilder $container
34
     */
35
    public function build(ContainerBuilder $container)
36
    {
37
        parent::build($container);
38
39
        $container->addCompilerPass(new EventCompilerPass());
40
    }
41
}
42