Total Complexity | 7 |
Total Lines | 70 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php declare(strict_types=1); |
||
16 | class PromiseMany implements PromiseInterface |
||
17 | { |
||
18 | /** @var ORMInterface @internal */ |
||
19 | private $orm; |
||
20 | |||
21 | /** @var string */ |
||
22 | private $target; |
||
23 | |||
24 | /** @var array */ |
||
25 | private $query = []; |
||
26 | |||
27 | /** @var array */ |
||
28 | private $where = []; |
||
29 | |||
30 | /** @var array */ |
||
31 | private $resolved = []; |
||
32 | |||
33 | /** |
||
34 | * @param ORMInterface $orm |
||
35 | * @param string $target |
||
36 | * @param array $query |
||
37 | * @param array $where |
||
38 | */ |
||
39 | public function __construct(ORMInterface $orm, string $target, array $query = [], array $where = []) |
||
40 | { |
||
41 | $this->orm = $orm; |
||
42 | $this->target = $target; |
||
43 | $this->query = $query; |
||
44 | $this->where = $where; |
||
45 | } |
||
46 | |||
47 | /** |
||
48 | * @inheritdoc |
||
49 | */ |
||
50 | public function __loaded(): bool |
||
53 | } |
||
54 | |||
55 | /** |
||
56 | * @inheritdoc |
||
57 | */ |
||
58 | public function __role(): string |
||
59 | { |
||
60 | return $this->target; |
||
61 | } |
||
62 | |||
63 | /** |
||
64 | * @inheritdoc |
||
65 | */ |
||
66 | public function __scope(): array |
||
69 | } |
||
70 | |||
71 | /** |
||
72 | * @inheritdoc |
||
73 | */ |
||
74 | public function __resolve() |
||
86 | } |
||
87 | } |