From 541318cb81710ef080b30cc790681ace773c11ac Mon Sep 17 00:00:00 2001 From: Bernhard Posselt Date: Mon, 12 May 2014 23:05:43 +0200 Subject: more fixes --- fetcher/feedfetcher.php | 2 ++ fetcher/fetcher.php | 13 ++++++++++++- fetcher/ifeedfetcher.php | 5 +++-- 3 files changed, 17 insertions(+), 3 deletions(-) (limited to 'fetcher') diff --git a/fetcher/feedfetcher.php b/fetcher/feedfetcher.php index 52da1f648..ca9367a95 100644 --- a/fetcher/feedfetcher.php +++ b/fetcher/feedfetcher.php @@ -60,6 +60,8 @@ class FeedFetcher implements IFeedFetcher { /** * Fetch a feed from remote * @param string url remote url of the feed + * @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 */ diff --git a/fetcher/fetcher.php b/fetcher/fetcher.php index 3d5780f7e..50017b7a5 100644 --- a/fetcher/fetcher.php +++ b/fetcher/fetcher.php @@ -23,11 +23,22 @@ class Fetcher { } + /** + * Add an additional fetcher + * @param IFeedFetcher $fetcher the fetcher + */ public function registerFetcher(IFeedFetcher $fetcher){ array_push($this->fetchers, $fetcher); } - + /** + * Fetch a feed from remote + * @param string url remote url of the feed + * @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 + */ public function fetch($url, $getFavicon=true){ foreach($this->fetchers as $fetcher){ if($fetcher->canHandle($url)){ diff --git a/fetcher/ifeedfetcher.php b/fetcher/ifeedfetcher.php index 9bfb4957d..9cdde5cdf 100644 --- a/fetcher/ifeedfetcher.php +++ b/fetcher/ifeedfetcher.php @@ -16,8 +16,9 @@ namespace OCA\News\Fetcher; interface IFeedFetcher { /** - * @param string url the url that the user entered in the add feed dialog - * box + * @param string url remote url of the feed + * @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 -- cgit v1.2.3