Configuration   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 32
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 3

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 3
dl 0
loc 32
ccs 20
cts 20
cp 1
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
B getConfigTreeBuilder() 0 26 1
1
<?php
2
3
namespace Zenstruck\AssetManifestBundle\DependencyInjection;
4
5
use Symfony\Component\Config\Definition\Builder\TreeBuilder;
6
use Symfony\Component\Config\Definition\ConfigurationInterface;
7
8
/**
9
 * @author Kevin Bond <[email protected]>
10
 */
11
final class Configuration implements ConfigurationInterface
12
{
13
    /**
14
     * {@inheritdoc}
15
     */
16 4
    public function getConfigTreeBuilder()
17
    {
18 4
        $treeBuilder = new TreeBuilder();
19 4
        $rootNode = $treeBuilder->root('zenstruck_asset_manifest');
20
21
        $rootNode
22 4
            ->children()
23 4
                ->scalarNode('manifest_file')
24 4
                    ->defaultNull()
25 4
                ->end()
26 4
                ->arrayNode('prefix')
27 4
                    ->addDefaultsIfNotSet()
28 4
                    ->children()
29 4
                        ->scalarNode('source')
30 4
                            ->defaultNull()
31 4
                        ->end()
32 4
                        ->scalarNode('destination')
33 4
                            ->defaultNull()
34 4
                        ->end()
35 4
                    ->end()
36 4
                ->end()
37 4
            ->end()
38
        ;
39
40 4
        return $treeBuilder;
41
    }
42
}
43