Completed
Push — master ( fe1dad...5b05e2 )
by Eric
07:08
created

IvoryFormExtraExtension::load()   A

Complexity

Conditions 2
Paths 2

Size

Total Lines 8
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 8
rs 9.4285
cc 2
eloc 4
nc 2
nop 2
1
<?php
2
3
/*
4
 * This file is part of the Ivory Form Extra package.
5
 *
6
 * (c) Eric GELOEN <[email protected]>
7
 *
8
 * For the full copyright and license information, please read the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace Ivory\FormExtraBundle\DependencyInjection;
13
14
use Symfony\Component\Config\FileLocator;
15
use Symfony\Component\DependencyInjection\ContainerBuilder;
16
use Symfony\Component\DependencyInjection\Extension\Extension;
17
use Symfony\Component\DependencyInjection\Loader\XmlFileLoader;
18
19
/**
20
 * Ivory Form Extra extension.
21
 *
22
 * @author GeLo <[email protected]>
23
 */
24
class IvoryFormExtraExtension extends Extension
25
{
26
    /**
27
     * {@inheritdoc}
28
     */
29
    public function load(array $config, ContainerBuilder $container)
30
    {
31
        $loader = new XmlFileLoader($container, new FileLocator(__DIR__.'/../Resources/config'));
32
33
        foreach (array('templating', 'twig') as $service) {
34
            $loader->load($service.'.xml');
35
        }
36
    }
37
}
38