SpomkyLabsJoseBundle::build()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 8
Code Lines 5

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 8
rs 9.4285
c 0
b 0
f 0
cc 1
eloc 5
nc 1
nop 1
1
<?php
2
3
/*
4
 * The MIT License (MIT)
5
 *
6
 * Copyright (c) 2014-2016 Spomky-Labs
7
 *
8
 * This software may be modified and distributed under the terms
9
 * of the MIT license.  See the LICENSE file for details.
10
 */
11
12
namespace SpomkyLabs\JoseBundle;
13
14
use SpomkyLabs\JoseBundle\DependencyInjection\Compiler\AlgorithmCompilerPass;
15
use SpomkyLabs\JoseBundle\DependencyInjection\Compiler\CheckerCompilerPass;
16
use SpomkyLabs\JoseBundle\DependencyInjection\Compiler\CompressionCompilerPass;
17
use SpomkyLabs\JoseBundle\DependencyInjection\SpomkyLabsJoseBundleExtension;
18
use Symfony\Component\DependencyInjection\ContainerBuilder;
19
use Symfony\Component\HttpKernel\Bundle\Bundle;
20
21
final class SpomkyLabsJoseBundle extends Bundle
22
{
23
    /**
24
     * {@inheritdoc}
25
     */
26
    public function getContainerExtension()
27
    {
28
        return new SpomkyLabsJoseBundleExtension('jose', __DIR__);
29
    }
30
31
    /**
32
     * {@inheritdoc}
33
     */
34
    public function build(ContainerBuilder $container)
35
    {
36
        parent::build($container);
37
38
        $container->addCompilerPass(new AlgorithmCompilerPass());
39
        $container->addCompilerPass(new CompressionCompilerPass());
40
        $container->addCompilerPass(new CheckerCompilerPass());
41
    }
42
}
43