public function setRoomType($roomType) { if (!RoomType::isValidRoomType($roomType)) { throw new Exception("Room type is not valid."); } $this->roomType = $roomType; }