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

Pipeline::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

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