DoLLdapBundle   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 10
Duplicated Lines 0 %

Test Coverage

Coverage 0%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 5
c 1
b 0
f 0
dl 0
loc 10
ccs 0
cts 6
cp 0
rs 10
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A build() 0 8 1
1
<?php
2
3
namespace DoL\LdapBundle;
4
5
use DoL\LdapBundle\Security\Factory\FormLoginLdapFactory;
6
use DoL\LdapBundle\Security\Factory\HttpBasicLdapFactory;
7
use Symfony\Bundle\SecurityBundle\DependencyInjection\SecurityExtension;
8
use Symfony\Component\DependencyInjection\ContainerBuilder;
9
use Symfony\Component\HttpKernel\Bundle\Bundle;
10
11
/**
12
 * DoLLdapBundle.
13
 *
14
 * @author DarwinOnLine
15
 * @author Maks3w
16
 *
17
 * @see https://github.com/DarwinOnLine/DoLLdapBundle
18
 */
19
class DoLLdapBundle extends Bundle
20
{
21
    public function build(ContainerBuilder $container)
22
    {
23
        parent::build($container);
24
25
        /** @var SecurityExtension $extension */
26
        $extension = $container->getExtension('security');
27
        $extension->addSecurityListenerFactory(new FormLoginLdapFactory());
28
        $extension->addSecurityListenerFactory(new HttpBasicLdapFactory());
29
    }
30
}
31