Completed
Push — master ( 72ff63...b0fbbf )
by Kirill
01:35 queued 01:31
created

GuardNamespace::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 1
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
<?php
2
3
/**
4
 * Spiral Framework.
5
 *
6
 * @license   MIT
7
 * @author    Anton Titov (Wolfy-J)
8
 */
9
10
declare(strict_types=1);
11
12
namespace Spiral\Domain\Annotation;
13
14
use Attribute;
15
use Doctrine\Common\Annotations\Annotation;
16
use Spiral\Attributes\NamedArgumentConstructor;
17
18
/**
19
 * @Annotation()
20
 * @Annotation\Target({"CLASS"})
21
 * @NamedArgumentConstructor()
22
 */
23
#[Attribute(Attribute::TARGET_CLASS)]
24
#[NamedArgumentConstructor()]
25
final class GuardNamespace
26
{
27
    /**
28
     * @Annotation\Attribute(name="namespace", type="string", required=true)
29
     * @type string
30
     */
31
    public $namespace;
32
33
    public function __construct(string $namespace)
34
    {
35
        $this->namespace = $namespace;
36
    }
37
}
38