Total Complexity | 5 |
Total Lines | 38 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
10 | trait ForeignKeyAnalyzerTrait |
||
11 | { |
||
12 | /** |
||
13 | * @var Annotations[] |
||
14 | */ |
||
15 | private $annotations; |
||
16 | /** |
||
17 | * @var Column[] |
||
18 | */ |
||
19 | private $localColumns; |
||
20 | |||
21 | /** |
||
22 | * @return Column[] |
||
23 | */ |
||
24 | private function getLocalColumns(): array |
||
25 | { |
||
26 | if ($this->localColumns === null) { |
||
27 | $localColumnNames = $this->foreignKey->getUnquotedLocalColumns(); |
||
28 | |||
29 | $this->localColumns = array_map([$this->foreignKey->getLocalTable(), 'getColumn'], $localColumnNames); |
||
30 | } |
||
31 | return $this->localColumns; |
||
32 | } |
||
33 | |||
34 | /** |
||
35 | * @return Annotations[] |
||
36 | */ |
||
37 | private function getAnnotations(): array |
||
48 | } |
||
49 | } |
||
50 |