/** * Set remote content * * @param SimpleXMLElement $xml * @return void */ private function setRemoteContent(\SimpleXMLElement $xml) { $this->remoteContent = new \Doctrine\Common\Collections\ArrayCollection(); foreach ($xml->children() as $remoteContentXml) { $this->remoteContent->add(RemoteContent::createFromXml($remoteContentXml)); } }
/** * Get remote content src * * @param Newscoop\News\RemoteContent $remoteContent * @return string */ public function getRemoteContentSrc(RemoteContent $remoteContent) { return sprintf('%s?token=%s', $remoteContent->getHref(), $this->getToken()); }