SfCodSocketIoBundle   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 22
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 4

Importance

Changes 0
Metric Value
wmc 2
lcom 0
cbo 4
dl 0
loc 22
rs 10
c 0
b 0
f 0

2 Methods

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