Passed
Push — master ( a71cc4...1302d4 )
by Vincent
21:00 queued 11:57
created

Configuration::getConfigTreeBuilder()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 16
Code Lines 12

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 13
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 12
c 1
b 0
f 0
nc 1
nop 0
dl 0
loc 16
rs 9.8666
ccs 13
cts 13
cp 1
crap 1
1
<?php
2
3
namespace Bdf\SerializerBundle\DependencyInjection;
4
5
use Symfony\Component\Config\Definition\Builder\TreeBuilder;
6
use Symfony\Component\Config\Definition\ConfigurationInterface;
7
8
/**
9
 * Configuration
10
 */
11
class Configuration implements ConfigurationInterface
12
{
13
    /**
14
     * {@inheritDoc}
15
     */
16 8
    public function getConfigTreeBuilder()
17
    {
18 8
        $treeBuilder = new TreeBuilder('bdf_serializer');
19 8
        $treeBuilder->getRootNode()
20 8
            ->children()
21 8
                ->arrayNode('cache')
22 8
                    ->info('The metadata cache service. Should implement Psr\SimpleCache\CacheInterface.')
23 8
                    ->children()
24 8
                        ->scalarNode('pool')->end()
25 8
                        ->scalarNode('service')->end()
26 8
                    ->end()
27 8
                ->end()
28 8
            ->end()
29
        ;
30
31 8
        return $treeBuilder;
32
    }
33
}
34