|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jasig.portlet.notice.service.CacheNotificationService
public class CacheNotificationService
This class contains all the notification service providers. It implements the EHCache implementation. An instance of this class is called from the DataController in order to retrieve the notifications for a given user.
| Constructor Summary | |
|---|---|
CacheNotificationService()
|
|
| Method Summary | |
|---|---|
NotificationResponse |
fetchNotificationsFromSource(javax.portlet.PortletRequest req)
Gathers the collection of notifications for the user associated with the srequest. |
String |
getName()
Returns the name of the service. |
NotificationResponse |
getNotifications(String notificationsContextName,
String remoteUser,
javax.portlet.PortletRequest req)
Most implementations need do nothing special with this method. |
void |
refreshNotifications(String notificationsContextName,
String remoteUser)
After calling this method, the next call to getNotifications will cause the notifications to be fetched from their source(s), not from cache. |
void |
setEmbeddedServices(List<INotificationService> embeddedServices)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CacheNotificationService()
| Method Detail |
|---|
public String getName()
getName in interface INotificationService
@Cacheable(cacheName="notificationCache",
keyGenerator=@KeyGenerator(name="HashCodeCacheKeyGenerator",properties=@Property(name="includeMethod",value="false")))
public NotificationResponse getNotifications(@PartialCacheKey
String notificationsContextName,
@PartialCacheKey
String remoteUser,
javax.portlet.PortletRequest req)
throws NotificationServiceException
INotificationService
getNotifications in interface INotificationServicenotificationsContextName - Configured in the -portlet.xml Spring fileremoteUser - From req.getRemoteUserreq - The PortletRequest
NotificationServiceException
@TriggersRemove(cacheName="notificationCache",
keyGenerator=@KeyGenerator(name="HashCodeCacheKeyGenerator",properties=@Property(name="includeMethod",value="false")))
public void refreshNotifications(String notificationsContextName,
String remoteUser)
INotificationService
refreshNotifications in interface INotificationService
public NotificationResponse fetchNotificationsFromSource(javax.portlet.PortletRequest req)
throws NotificationServiceException
INotificationService
fetchNotificationsFromSource in interface INotificationServicereq - The PortletRequest
NotificationServiceExceptionpublic void setEmbeddedServices(List<INotificationService> embeddedServices)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||