Total Complexity | 2 |
Total Lines | 26 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 2 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
7 | abstract class Model implements CreatableFromArray |
||
8 | { |
||
9 | /** |
||
10 | * @var array |
||
11 | */ |
||
12 | protected $data; |
||
13 | |||
14 | 35 | protected function __construct(array $data) |
|
17 | 35 | } |
|
18 | |||
19 | 35 | public static function createFromArray(array $data) |
|
27 | } |
||
28 | |||
29 | /** |
||
30 | * @return string[] |
||
31 | */ |
||
32 | abstract protected static function getFields(): array; |
||
33 | } |
||
34 |