| Total Complexity | 3 |
| Total Lines | 35 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 19 | class News extends Message |
||
| 20 | { |
||
| 21 | /** |
||
| 22 | * @var string |
||
| 23 | */ |
||
| 24 | protected $type = 'news'; |
||
| 25 | |||
| 26 | /** |
||
| 27 | * @var array |
||
| 28 | */ |
||
| 29 | protected $properties = ['items']; |
||
| 30 | |||
| 31 | /** |
||
| 32 | * News constructor. |
||
| 33 | * |
||
| 34 | * @param array $items |
||
| 35 | */ |
||
| 36 | 2 | public function __construct(array $items = []) |
|
| 37 | { |
||
| 38 | 2 | parent::__construct(compact('items')); |
|
| 39 | 2 | } |
|
| 40 | |||
| 41 | /** |
||
| 42 | * @param array $data |
||
| 43 | * @param array $aliases |
||
| 44 | * |
||
| 45 | * @return array |
||
| 46 | */ |
||
| 47 | public function propertiesToArray(array $data, array $aliases = []): array |
||
| 54 | } |
||
| 55 | } |
||
| 56 |