Passed
Push — master ( b4fb65...8688ba )
by Marcel
02:35
created

Configuration   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 14
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 1
eloc 9
dl 0
loc 14
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A getConfigTreeBuilder() 0 12 1
1
<?php
2
3
/*
4
 * This file is part of the SaasProviderBundle package.
5
 * (c) Fluxter <http://fluxter.net/>
6
 * For the full copyright and license information, please view the LICENSE
7
 * file that was distributed with this source code.
8
 */
9
10
namespace Fluxter\SaasProviderBundle\DependencyInjection;
11
12
use Symfony\Component\Config\Definition\Builder\TreeBuilder;
13
use Symfony\Component\Config\Definition\ConfigurationInterface;
14
15
class Configuration implements ConfigurationInterface
16
{
17
    public function getConfigTreeBuilder()
18
    {
19
        $treeBuilder = new TreeBuilder('saas_provider');
20
21
        $treeBuilder->getRootNode()
22
            ->children()
23
            ->scalarNode('client_entity')->isRequired()->cannotBeEmpty()->end()
24
            ->scalarNode('apikey')->isRequired()->cannotBeEmpty()->end()
25
            ->end()
26
            ->end();
27
28
        return $treeBuilder;
29
    }
30
}
31