Completed
Push — master ( 1f2b71...3f1d1d )
by Matze
07:04
created

CompilerPass::getBuilder()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 2
crap 1
1
<?php
2
3
namespace BrainExe\Core\Annotations;
4
5
use BrainExe\Annotations\Annotations\Service;
6
use BrainExe\Core\Annotations\Builder\CompilerPass as Builder;
7
use Doctrine\Common\Annotations\Annotation;
8
use Doctrine\Common\Annotations\Reader;
9
use Symfony\Component\DependencyInjection\Compiler\PassConfig;
10
use Symfony\Component\DependencyInjection\ContainerBuilder;
11
12
/**
13
 * @Annotation
14
 * @api
15
 */
16
class CompilerPass extends Service
17
{
18
19
    /**
20
     * @var int
21
     */
22
    public $priority = 3;
23
24
    /**
25
     * @see PassConfig::TYPE_*
26
     * @var string|null
27
     */
28
    public $type = PassConfig::TYPE_BEFORE_OPTIMIZATION;
29
30
    /**
31
     * {@inheritdoc}
32
     */
33 1
    public static function getBuilder(ContainerBuilder $container, Reader $reader)
34
    {
35 1
        return new Builder($container, $reader);
36
    }
37
}
38