ZoomMeeting.php
84 lines
| 1 | <?php |
| 2 | |
| 3 | namespace AmeliaBooking\Domain\Entity\Zoom; |
| 4 | |
| 5 | use AmeliaBooking\Domain\ValueObjects\Number\Integer\Id; |
| 6 | use AmeliaBooking\Domain\ValueObjects\String\Url; |
| 7 | |
| 8 | /** |
| 9 | * Class ZoomMeeting |
| 10 | * |
| 11 | * @package AmeliaBooking\Domain\Entity\Zoom |
| 12 | */ |
| 13 | class ZoomMeeting |
| 14 | { |
| 15 | /** @var Id */ |
| 16 | private $id; |
| 17 | |
| 18 | /** @var Url */ |
| 19 | private $joinUrl; |
| 20 | |
| 21 | /** @var Url */ |
| 22 | private $startUrl; |
| 23 | |
| 24 | /** |
| 25 | * @return Id |
| 26 | */ |
| 27 | public function getId() |
| 28 | { |
| 29 | return $this->id; |
| 30 | } |
| 31 | |
| 32 | /** |
| 33 | * @param Id $id |
| 34 | */ |
| 35 | public function setId(Id $id) |
| 36 | { |
| 37 | $this->id = $id; |
| 38 | } |
| 39 | |
| 40 | /** |
| 41 | * @return Url |
| 42 | */ |
| 43 | public function getJoinUrl() |
| 44 | { |
| 45 | return $this->joinUrl; |
| 46 | } |
| 47 | |
| 48 | /** |
| 49 | * @param Url $joinUrl |
| 50 | */ |
| 51 | public function setJoinUrl(Url $joinUrl) |
| 52 | { |
| 53 | $this->joinUrl = $joinUrl; |
| 54 | } |
| 55 | |
| 56 | /** |
| 57 | * @return Url |
| 58 | */ |
| 59 | public function getStartUrl() |
| 60 | { |
| 61 | return $this->startUrl; |
| 62 | } |
| 63 | |
| 64 | /** |
| 65 | * @param Url $startUrl |
| 66 | */ |
| 67 | public function setStartUrl(Url $startUrl) |
| 68 | { |
| 69 | $this->startUrl = $startUrl; |
| 70 | } |
| 71 | |
| 72 | /** |
| 73 | * @return array |
| 74 | */ |
| 75 | public function toArray() |
| 76 | { |
| 77 | return [ |
| 78 | 'id' => $this->getId() ? $this->getId()->getValue() : null, |
| 79 | 'startUrl' => $this->getStartUrl() ? $this->getStartUrl()->getValue() : null, |
| 80 | 'joinUrl' => $this->getJoinUrl() ? $this->getJoinUrl()->getValue() : null, |
| 81 | ]; |
| 82 | } |
| 83 | } |
| 84 |