com.liferay.portal.notifications
Class ChannelHubImpl
java.lang.Object
com.liferay.portal.notifications.ChannelHubImpl
- All Implemented Interfaces:
- ChannelHub
public class ChannelHubImpl
- extends Object
- implements ChannelHub
Method Summary |
void |
cleanUp()
|
void |
cleanUp(long userId)
|
ChannelHub |
clone(long companyId)
|
void |
confirmDelivery(long userId,
Collection<String> notificationEventUuids)
|
void |
confirmDelivery(long userId,
Collection<String> notificationEventUuids,
boolean archive)
|
void |
confirmDelivery(long userId,
String notificationEventUuid)
|
void |
confirmDelivery(long userId,
String notificationEventUuid,
boolean archive)
|
Channel |
createChannel(long userId)
|
void |
deleteUserNotificiationEvent(long userId,
String notificationEventUuid)
|
void |
deleteUserNotificiationEvents(long userId,
Collection<String> notificationEventUuids)
|
void |
destroy()
|
Channel |
destroyChannel(long userId)
|
Channel |
fetchChannel(long userId)
|
Channel |
fetchChannel(long userId,
boolean createIfAbsent)
|
List<NotificationEvent> |
fetchNotificationEvents(long userId)
|
List<NotificationEvent> |
fetchNotificationEvents(long userId,
boolean flush)
|
void |
flush()
|
void |
flush(long userId)
|
void |
flush(long userId,
long timestamp)
|
Channel |
getChannel(long userId)
|
Channel |
getChannel(long userId,
boolean createIfAbsent)
|
long |
getCompanyId()
|
List<NotificationEvent> |
getNotificationEvents(long userId)
|
List<NotificationEvent> |
getNotificationEvents(long userId,
boolean flush)
|
Collection<Long> |
getUserIds()
|
void |
registerChannelListener(long userId,
ChannelListener channelListener)
|
void |
removeTransientNotificationEvents(long userId,
Collection<NotificationEvent> notificationEvents)
|
void |
removeTransientNotificationEventsByUuid(long userId,
Collection<String> notificationEventUuids)
|
void |
sendNotificationEvent(long userId,
NotificationEvent notificationEvent)
|
void |
sendNotificationEvents(long userId,
Collection<NotificationEvent> notificationEvents)
|
void |
setChannelPrototype(Channel channel)
|
void |
setCompanyId(long companyId)
|
void |
storeNotificationEvent(long userId,
NotificationEvent notificationEvent)
|
void |
unregisterChannelListener(long userId,
ChannelListener channelListener)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ChannelHubImpl
public ChannelHubImpl()
cleanUp
public void cleanUp()
throws ChannelException
- Specified by:
cleanUp
in interface ChannelHub
- Throws:
ChannelException
cleanUp
public void cleanUp(long userId)
throws ChannelException
- Specified by:
cleanUp
in interface ChannelHub
- Throws:
ChannelException
clone
public ChannelHub clone(long companyId)
- Specified by:
clone
in interface ChannelHub
confirmDelivery
public void confirmDelivery(long userId,
Collection<String> notificationEventUuids)
throws ChannelException
- Specified by:
confirmDelivery
in interface ChannelHub
- Throws:
ChannelException
confirmDelivery
public void confirmDelivery(long userId,
Collection<String> notificationEventUuids,
boolean archive)
throws ChannelException
- Specified by:
confirmDelivery
in interface ChannelHub
- Throws:
ChannelException
confirmDelivery
public void confirmDelivery(long userId,
String notificationEventUuid)
throws ChannelException
- Specified by:
confirmDelivery
in interface ChannelHub
- Throws:
ChannelException
confirmDelivery
public void confirmDelivery(long userId,
String notificationEventUuid,
boolean archive)
throws ChannelException
- Specified by:
confirmDelivery
in interface ChannelHub
- Throws:
ChannelException
createChannel
public Channel createChannel(long userId)
throws ChannelException
- Specified by:
createChannel
in interface ChannelHub
- Throws:
ChannelException
deleteUserNotificiationEvent
public void deleteUserNotificiationEvent(long userId,
String notificationEventUuid)
throws ChannelException
- Specified by:
deleteUserNotificiationEvent
in interface ChannelHub
- Throws:
ChannelException
deleteUserNotificiationEvents
public void deleteUserNotificiationEvents(long userId,
Collection<String> notificationEventUuids)
throws ChannelException
- Specified by:
deleteUserNotificiationEvents
in interface ChannelHub
- Throws:
ChannelException
destroy
public void destroy()
throws ChannelException
- Specified by:
destroy
in interface ChannelHub
- Throws:
ChannelException
destroyChannel
public Channel destroyChannel(long userId)
throws ChannelException
- Specified by:
destroyChannel
in interface ChannelHub
- Throws:
ChannelException
fetchChannel
public Channel fetchChannel(long userId)
throws ChannelException
- Specified by:
fetchChannel
in interface ChannelHub
- Throws:
ChannelException
fetchChannel
public Channel fetchChannel(long userId,
boolean createIfAbsent)
throws ChannelException
- Specified by:
fetchChannel
in interface ChannelHub
- Throws:
ChannelException
fetchNotificationEvents
public List<NotificationEvent> fetchNotificationEvents(long userId)
throws ChannelException
- Specified by:
fetchNotificationEvents
in interface ChannelHub
- Throws:
ChannelException
fetchNotificationEvents
public List<NotificationEvent> fetchNotificationEvents(long userId,
boolean flush)
throws ChannelException
- Specified by:
fetchNotificationEvents
in interface ChannelHub
- Throws:
ChannelException
flush
public void flush()
throws ChannelException
- Specified by:
flush
in interface ChannelHub
- Throws:
ChannelException
flush
public void flush(long userId)
throws ChannelException
- Specified by:
flush
in interface ChannelHub
- Throws:
ChannelException
flush
public void flush(long userId,
long timestamp)
throws ChannelException
- Specified by:
flush
in interface ChannelHub
- Throws:
ChannelException
getChannel
public Channel getChannel(long userId)
throws ChannelException
- Specified by:
getChannel
in interface ChannelHub
- Throws:
ChannelException
getChannel
public Channel getChannel(long userId,
boolean createIfAbsent)
throws ChannelException
- Specified by:
getChannel
in interface ChannelHub
- Throws:
ChannelException
getCompanyId
public long getCompanyId()
getNotificationEvents
public List<NotificationEvent> getNotificationEvents(long userId)
throws ChannelException
- Specified by:
getNotificationEvents
in interface ChannelHub
- Throws:
ChannelException
getNotificationEvents
public List<NotificationEvent> getNotificationEvents(long userId,
boolean flush)
throws ChannelException
- Specified by:
getNotificationEvents
in interface ChannelHub
- Throws:
ChannelException
getUserIds
public Collection<Long> getUserIds()
- Specified by:
getUserIds
in interface ChannelHub
registerChannelListener
public void registerChannelListener(long userId,
ChannelListener channelListener)
throws ChannelException
- Specified by:
registerChannelListener
in interface ChannelHub
- Throws:
ChannelException
removeTransientNotificationEvents
public void removeTransientNotificationEvents(long userId,
Collection<NotificationEvent> notificationEvents)
throws ChannelException
- Specified by:
removeTransientNotificationEvents
in interface ChannelHub
- Throws:
ChannelException
removeTransientNotificationEventsByUuid
public void removeTransientNotificationEventsByUuid(long userId,
Collection<String> notificationEventUuids)
throws ChannelException
- Specified by:
removeTransientNotificationEventsByUuid
in interface ChannelHub
- Throws:
ChannelException
sendNotificationEvent
public void sendNotificationEvent(long userId,
NotificationEvent notificationEvent)
throws ChannelException
- Specified by:
sendNotificationEvent
in interface ChannelHub
- Throws:
ChannelException
sendNotificationEvents
public void sendNotificationEvents(long userId,
Collection<NotificationEvent> notificationEvents)
throws ChannelException
- Specified by:
sendNotificationEvents
in interface ChannelHub
- Throws:
ChannelException
setChannelPrototype
public void setChannelPrototype(Channel channel)
setCompanyId
public void setCompanyId(long companyId)
storeNotificationEvent
public void storeNotificationEvent(long userId,
NotificationEvent notificationEvent)
throws ChannelException
- Specified by:
storeNotificationEvent
in interface ChannelHub
- Throws:
ChannelException
unregisterChannelListener
public void unregisterChannelListener(long userId,
ChannelListener channelListener)
throws ChannelException
- Specified by:
unregisterChannelListener
in interface ChannelHub
- Throws:
ChannelException