Total Complexity | 4 |
Total Lines | 39 |
Duplicated Lines | 0 % |
Coverage | 0% |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
17 | trait PrimaryKeys |
||
18 | { |
||
19 | use AbstractMetaData; |
||
20 | use Attribute; |
||
21 | |||
22 | /** |
||
23 | * Get Primary Key Attributes from models MetaData |
||
24 | */ |
||
25 | public function getPrimaryKeys(): array |
||
26 | { |
||
27 | assert($this instanceof ModelInterface); |
||
28 | return $this->getModelsMetaData()->getPrimaryKeyAttributes($this); |
||
29 | } |
||
30 | |||
31 | /** |
||
32 | * Get column map from models MetaData |
||
33 | */ |
||
34 | public function getColumnMap(): array |
||
38 | } |
||
39 | |||
40 | /** |
||
41 | * Get an array of primary keys values |
||
42 | */ |
||
43 | public function getPrimaryKeysValues(): array |
||
56 | } |
||
57 | } |
||
58 |