public function populateFromEntry(LiveStreamEntry $entry) { $this->setEncoderIP($entry->getEncodingIP1()); $this->setBackupEncoderIP($entry->getEncodingIP2()); $this->setEncoderPassword($entry->getStreamPassword()); $this->setEncoderUsername($entry->getStreamUsername()); $this->setDvrEnabled($entry->getDvrStatus()); $this->setDvrWindow($entry->getDvrWindow()); $this->setStreamType(AkamaiUniversalStreamType::UNIVERSAL_STREAMING_LIVE); $this->setStreamName(str_replace("_", "", $entry->getId())); }
protected function getBroadcastUrl(LiveStreamEntry $entry, $protocol, $hostname, $mediaServerIndex, $concatStreamName = false) { if (!$hostname) { return ''; } $url = "{$protocol}://{$hostname}"; $params = array('p' => $this->partnerId, 'e' => $entry->getId(), 'i' => $mediaServerIndex, 't' => $entry->getStreamPassword()); $paramsStr = http_build_query($params); $streamName = ''; if ($concatStreamName) { $streamName = $entry->getId() . '_%i'; } return "{$url}/{$streamName}?{$paramsStr}"; }
public function populateFromEntry(LiveStreamEntry $entry) { $this->setEncoderIP($entry->getEncodingIP1()); $this->setBackupEncoderIP($entry->getEncodingIP2()); $this->setEncoderPassword($entry->getStreamPassword()); $this->setEncoderUsername($entry->getStreamUsername()); $this->setEndDate($entry->getEndDate(null)); $this->setMediaType($entry->getMediaType()); }