public class RssManager
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
PUBLICATION_DATE |
Modifier and Type | Method and Description |
---|---|
void |
addDefaultListener(RssEventListener listener)
Add
RssEventListener |
void |
addDefaultListeners(java.util.Set<RssEventListener> listeners)
Add
RssEventListener set to existing listeners |
void |
cleanRssTracker(Member member,
java.lang.String channelSource,
java.util.List<java.lang.String> itemIdList)
Clean rssTracker table
|
java.util.Set<RssEventListener> |
getDefaultListeners()
returns the
RssEventListener set |
static RssManager |
getInstance() |
RssEventListener |
getRssTrackerListener()
Get Rss tracker listener
|
java.util.Set<RssTracker> |
getSessionRssTrackerSet(Member member)
Returns
RssTracker set for a member |
static java.util.List<RssItem> |
getSortItemList(java.util.List<RssItem> itemList,
java.lang.String sortAttribute)
generated a sorted
List of the provided List . |
RssTracker |
isRead(Member member,
java.lang.String channelSource,
java.lang.String itemId,
java.util.Set<RssTracker> trackersSet)
Indicates if a rss is already read
|
void |
processRssTrackingEvent(Member currentLoggedMember,
java.lang.String channelSource,
java.lang.String itemId,
boolean articleRead)
Process tracking event
|
void |
removeDefaultListener(RssEventListener listener)
Remove
RssEventListener from existing listener |
void |
removeDefaultListeners(java.util.List<RssEventListener> listeners)
Remove
RssEventListener from listener list |
void |
setDefaultListeners(java.util.Set<RssEventListener> listeners) |
public static RssManager getInstance()
public java.util.Set<RssEventListener> getDefaultListeners()
RssEventListener
setpublic void setDefaultListeners(java.util.Set<RssEventListener> listeners)
listeners
- the RssEventListener
set to setpublic void addDefaultListeners(java.util.Set<RssEventListener> listeners)
RssEventListener
set to existing listenerslisteners
- the setpublic void removeDefaultListeners(java.util.List<RssEventListener> listeners)
RssEventListener
from listener listlisteners
- the RssEventListener
to removepublic void addDefaultListener(RssEventListener listener)
RssEventListener
listener
- the RssEventListener
public void removeDefaultListener(RssEventListener listener)
RssEventListener
from existing listenerlistener
- the RssEventListener
public RssEventListener getRssTrackerListener()
public void processRssTrackingEvent(Member currentLoggedMember, java.lang.String channelSource, java.lang.String itemId, boolean articleRead)
currentLoggedMember
- the current Member
channelSource
- the channel sourceitemId
- the item idpublic java.util.Set<RssTracker> getSessionRssTrackerSet(Member member)
RssTracker
set for a membermember
- the Member
Set
of RssTracker
public RssTracker isRead(Member member, java.lang.String channelSource, java.lang.String itemId, java.util.Set<RssTracker> trackersSet)
member
- the current Member
channelSource
- the channel sourceitemId
- the item idtrackersSet
- Set
of existing RssTracker
public void cleanRssTracker(Member member, java.lang.String channelSource, java.util.List<java.lang.String> itemIdList)
member
- the Member
objectchannelSource
- the channel sourceitemIdList
- List
of item id to cleanpublic static java.util.List<RssItem> getSortItemList(java.util.List<RssItem> itemList, java.lang.String sortAttribute)
itemList
- the List
of RssItem
to sortsortAttribute
- the sort attribute (null for no sort, available element is publicationDate)List
if any sort should be done (in this case, the list is cloned)Copyright © 2001-2018 Jalios SA. All Rights Reserved.