Completed
Push — master ( 4fe349...ebd167 )
by Narcotic
05:21 queued 02:56
created

GravitonJsonSchemaExtension::load()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 1
Bugs 0 Features 1
Metric Value
c 1
b 0
f 1
dl 0
loc 5
ccs 0
cts 5
cp 0
rs 9.4285
nc 1
cc 1
eloc 3
nop 2
crap 2
1
<?php
2
/**
3
 * GravitonJsonSchemaExtension class file
4
 */
5
6
namespace Graviton\JsonSchemaBundle\DependencyInjection;
7
8
use Symfony\Component\Config\FileLocator;
9
use Symfony\Component\DependencyInjection\ContainerBuilder;
10
use Symfony\Component\DependencyInjection\Extension\Extension;
11
use Symfony\Component\DependencyInjection\Loader\XmlFileLoader;
12
13
/**
14
 * JSON schema extension
15
 *
16
 * @author   List of contributors <https://github.com/libgraviton/graviton/graphs/contributors>
17
 * @license  http://opensource.org/licenses/gpl-license.php GNU Public License
18
 * @link     http://swisscom.ch
19
 */
20
class GravitonJsonSchemaExtension extends Extension
21
{
22
    /**
23
     * Loads a specific configuration.
24
     *
25
     * @param array            $configs   An array of configuration values
26
     * @param ContainerBuilder $container A ContainerBuilder instance
27
     * @return void
28
     */
29
    public function load(array $configs, ContainerBuilder $container)
30
    {
31
        $loader = new XmlFileLoader($container, new FileLocator(__DIR__.'/../Resources/config'));
32
        $loader->load('services.xml');
33
    }
34
}
35