Total Complexity | 2 |
Total Lines | 24 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 1 |
1 | <?php |
||
24 | trait GetAssociationTrait |
||
25 | { |
||
26 | /** |
||
27 | * Getter for Table object. |
||
28 | * |
||
29 | * @return \Cake\ORM\Table |
||
30 | */ |
||
31 | abstract public function table(); |
||
32 | |||
33 | /** |
||
34 | * Get association for a relation. |
||
35 | * |
||
36 | * @param string $relation Relation name. |
||
37 | * @return \Cake\ORM\Association|null |
||
38 | */ |
||
39 | protected function getAssociation(string $relation): ?Association |
||
50 |