public interface NewsService
extends org.sakaiproject.entity.api.EntityProducer
NewsService is the interface for retrieving and caching news items from a rss news feed.
| Modifier and Type | Field and Description |
|---|---|
static String |
REFERENCE_ROOT
This string starts the references to resources in this service.
|
static String |
SERVICE_NAME
This string can be used to find the service in the service manager.
|
| Modifier and Type | Method and Description |
|---|---|
NewsChannel |
getChannel(String source)
Retrieves a NewsChannel object indexed by a URL.
|
List |
getNewsitems(String channel)
Retrieves a list of items from an rss feed.
|
List |
getNewsitems(String channel,
org.sakaiproject.javax.Filter filter)
Retrieves a list of items from an rss feed.
|
boolean |
isUpdateAvailable(String channel)
Checks whether an update is available for the rss news feed.
|
void |
removeChannel(String channel)
Retrieves a list of rss feeds that are being used.
|
static final String SERVICE_NAME
static final String REFERENCE_ROOT
NewsChannel getChannel(String source) throws NewsConnectionException, NewsFormatException
source - The url for the channel.NewsConnectionExceptionNewsFormatExceptionvoid removeChannel(String channel)
? - if param channel is not a valid url.List getNewsitems(String channel) throws NewsConnectionException, NewsFormatException
channel - The url for the feed.? - if param feed is not a valid url.NewsConnectionExceptionNewsFormatExceptionList getNewsitems(String channel, org.sakaiproject.javax.Filter filter) throws NewsConnectionException, NewsFormatException
channel - The url for the feed.filter - A filtering object to accept NewsItems, or null if no filtering is desired.? - if param feed is not a valid url.NewsConnectionExceptionNewsFormatExceptionboolean isUpdateAvailable(String channel)
feed - The url for the feed.? - if param feed is not a valid url.Copyright © 2003-2016 The Sakai Foundation. All Rights Reserved.