| 1 | <?php |
||
| 5 | class Row |
||
| 6 | { |
||
| 7 | /** |
||
| 8 | * The cells in this row |
||
| 9 | * @var Cell[] |
||
| 10 | */ |
||
| 11 | protected $cells = []; |
||
| 12 | |||
| 13 | /** |
||
| 14 | * Row constructor. |
||
| 15 | * @param Cell[] $cells |
||
| 16 | */ |
||
| 17 | 30 | public function __construct(array $cells) |
|
| 21 | |||
| 22 | /** |
||
| 23 | * @return Cell[] $cells |
||
| 24 | */ |
||
| 25 | 4 | public function getCells() |
|
| 26 | { |
||
| 27 | 4 | return $this->cells; |
|
| 28 | } |
||
| 29 | |||
| 30 | /** |
||
| 31 | * @param Cell[] $cells |
||
| 32 | * @return $this |
||
| 33 | */ |
||
| 34 | 30 | public function setCells(array $cells) |
|
| 43 | |||
| 44 | /** |
||
| 45 | * @param Cell $cell |
||
| 46 | * @return Row |
||
| 47 | */ |
||
| 48 | 29 | public function addCell(Cell $cell) |
|
| 54 | |||
| 55 | /** |
||
| 56 | * @return array The row values, as array |
||
| 57 | */ |
||
| 58 | public function toArray() |
||
| 64 | } |
||
| 65 |