1 | <?php |
||
7 | class Row |
||
8 | { |
||
9 | /** @var string */ |
||
10 | private $label; |
||
11 | |||
12 | /** @var array */ |
||
13 | private $events; |
||
14 | |||
15 | /** @var array */ |
||
16 | private $records = []; |
||
17 | |||
18 | /** |
||
19 | * Row constructor. |
||
20 | * |
||
21 | * @param string $label |
||
22 | * @param array $events |
||
23 | */ |
||
24 | public function __construct(string $label, array $events) |
||
31 | |||
32 | /** |
||
33 | * Fill blank data. |
||
34 | */ |
||
35 | private function fill() |
||
41 | |||
42 | /** |
||
43 | * @return string |
||
44 | */ |
||
45 | public function getLabel(): string |
||
49 | |||
50 | /** |
||
51 | * @return array |
||
52 | */ |
||
53 | public function getEvents(): array |
||
57 | |||
58 | /** |
||
59 | * Add value to event. |
||
60 | * |
||
61 | * @param string $event |
||
62 | * @param float $value |
||
63 | */ |
||
64 | public function addEvent(string $event, float $value) |
||
72 | } |