name; } public function getDescription(): string { return $this->description; } public function getLink(): string { return $this->link; } public function getLanguage(): string { return $this->language; } public function getCopyright(): string { return $this->copyright; } /** * @param array $props The properties of the Channel model * @return Channel */ public static function fromArray(array $props): Channel { $channel = new self( $props['name'], $props['description'] ?? '', $props['link'] ?? '', $props['language'] ?? '', $props['copyright'] ?? '', $props['explicit'] ?? false ); if ($props['id']) { $channel->setId($props['id']); } if ($props['createdAt']) { $channel->setCreatedAt($props['createdAt']); } if ($props['updatedAt']) { $channel->setUpdatedAt($props['updatedAt']); } return $channel; } }