diff options
-rw-r--r-- | articleenhancer/enhancer.php | 11 | ||||
-rw-r--r-- | fetcher/feedfetcher.php | 3 | ||||
-rw-r--r-- | fetcher/fetcher.php | 3 | ||||
-rw-r--r-- | fetcher/ifeedfetcher.php | 5 |
4 files changed, 17 insertions, 5 deletions
diff --git a/articleenhancer/enhancer.php b/articleenhancer/enhancer.php index 6fa617701..9d4a644ab 100644 --- a/articleenhancer/enhancer.php +++ b/articleenhancer/enhancer.php @@ -18,6 +18,10 @@ class Enhancer { private $enhancers = array(); + /** + * @param string $feedUrl + * @param ArticleEnhancer $enhancer + */ public function registerEnhancer($feedUrl, ArticleEnhancer $enhancer){ $feedUrl = $this->removeTrailingSlash($feedUrl); @@ -30,6 +34,10 @@ class Enhancer { } + /** + * @param \OCA\News\Db\Item $item + * @param string $feedUrl + */ public function enhance($item, $feedUrl){ $feedUrl = $this->removeTrailingSlash($feedUrl); @@ -41,6 +49,9 @@ class Enhancer { } + /** + * @param string $url + */ private function removeTrailingSlash($url) { if($url[strlen($url)-1] === '/') { return substr($url, 0, -1); diff --git a/fetcher/feedfetcher.php b/fetcher/feedfetcher.php index 436a92c70..9c2049395 100644 --- a/fetcher/feedfetcher.php +++ b/fetcher/feedfetcher.php @@ -63,7 +63,8 @@ class FeedFetcher implements IFeedFetcher { * @param boolean $getFavicon if the favicon should also be fetched, defaults * to true * @throws FetcherException if simple pie fails - * @return array an array containing the new feed and its items + * @return array(\OCA\News\Db\Feed, \OCA\News\Db\Item[]) an array containing + * the new feed and its items */ public function fetch($url, $getFavicon=true) { $simplePie = $this->simplePieFactory->getCore(); diff --git a/fetcher/fetcher.php b/fetcher/fetcher.php index f14dac0b6..a2ea42626 100644 --- a/fetcher/fetcher.php +++ b/fetcher/fetcher.php @@ -37,7 +37,8 @@ class Fetcher { * @param boolean $getFavicon if the favicon should also be fetched, defaults * to true * @throws FetcherException if simple pie fails - * @return array an array containing the new feed and its items + * @return array(\OCA\News\Db\Feed, \OCA\News\Db\Item[]) an array containing + * the new feed and its items */ public function fetch($url, $getFavicon=true){ foreach($this->fetchers as $fetcher){ diff --git a/fetcher/ifeedfetcher.php b/fetcher/ifeedfetcher.php index d380e9bb3..f53257613 100644 --- a/fetcher/ifeedfetcher.php +++ b/fetcher/ifeedfetcher.php @@ -20,9 +20,8 @@ interface IFeedFetcher { * @param boolean $getFavicon if the favicon should also be fetched, defaults * to true * @throws FetcherException if the fetcher encounters a problem - * @return array with the first element being the feed and the - * second element being an array of items. Those items will be saved into - * into the database + * @return array(\OCA\News\Db\Feed, \OCA\News\Db\Item[]) an array containing + * the new feed and its items */ function fetch($url, $getFavicon=true); |