Group.php
39 lines
| 1 | <?php |
| 2 | |
| 3 | namespace IAWP_SCOPED\IAWP\Tables\Groups; |
| 4 | |
| 5 | class Group |
| 6 | { |
| 7 | private $id; |
| 8 | private $singular; |
| 9 | private $plural; |
| 10 | private $table_data_class; |
| 11 | public function __construct(string $id, string $singular, string $plural, string $table_data_class) |
| 12 | { |
| 13 | $this->id = $id; |
| 14 | $this->singular = $singular; |
| 15 | $this->plural = $plural; |
| 16 | $this->table_data_class = $table_data_class; |
| 17 | } |
| 18 | public function id() : string |
| 19 | { |
| 20 | return $this->id; |
| 21 | } |
| 22 | public function has_id(string $id) : bool |
| 23 | { |
| 24 | return $this->id === $id; |
| 25 | } |
| 26 | public function singular() : string |
| 27 | { |
| 28 | return $this->singular; |
| 29 | } |
| 30 | public function plural() : string |
| 31 | { |
| 32 | return $this->plural; |
| 33 | } |
| 34 | public function table_data_class() : string |
| 35 | { |
| 36 | return $this->table_data_class; |
| 37 | } |
| 38 | } |
| 39 |