Completed
Push — master ( aeaead...324ed1 )
by Koen
04:45
created

Configuration   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 19
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 3

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
c 1
b 0
f 0
lcom 0
cbo 3
dl 0
loc 19
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A getConfigTreeBuilder() 0 13 1
1
<?php
2
3
namespace Ikoene\MarvelApiBundle\DependencyInjection;
4
5
use Symfony\Component\Config\Definition\Builder\TreeBuilder;
6
use Symfony\Component\Config\Definition\ConfigurationInterface;
7
8
/**
9
 * Class Configuration
10
 * @package Ikoene\MarvelApiBundle\DependencyInjection
11
 */
12
class Configuration implements ConfigurationInterface
13
{
14
    /**
15
     * {@inheritDoc}
16
     */
17
    public function getConfigTreeBuilder()
18
    {
19
        $treeBuilder = new TreeBuilder();
20
        $rootNode = $treeBuilder->root('ikoene_marvel_api');
21
        $rootNode
22
            ->children()
23
            ->scalarNode('public_api_key')->isRequired()->end()
24
            ->scalarNode('private_api_key')->isRequired()->end()
25
            ->end()
26
            ->end();
27
28
        return $treeBuilder;
29
    }
30
}
31