org.kuali.rice.ken.service.impl
Class NotificationMessageDeliveryServiceImpl

java.lang.Object
  extended by org.kuali.rice.ken.service.impl.NotificationMessageDeliveryServiceImpl
All Implemented Interfaces:
NotificationMessageDeliveryService

public class NotificationMessageDeliveryServiceImpl
extends Object
implements NotificationMessageDeliveryService

NotificationService implementation - this is the default out-of-the-box implementation of the service that uses the businessObjectDao to get at the data via our OOTB DBMS.

Author:
Kuali Rice Team (rice.collab@kuali.org)

Constructor Summary
NotificationMessageDeliveryServiceImpl(GenericDao businessObjectDao, NotificationMessegeDeliveryDao ntdDao)
          Constructs a NotificationServiceImpl class instance.
 
Method Summary
 Collection<NotificationMessageDelivery> getNotificationMessageDeliveries()
          This method will return all NotificationMessageDelivery objects in the system actual record.
 Collection<NotificationMessageDelivery> getNotificationMessageDeliveries(NotificationBo notification, String userRecipientId)
          This method will return all NotificationMessageDelievery objects generated for the given Notification for the given user
 NotificationMessageDelivery getNotificationMessageDelivery(Long id)
          This is the default implementation that uses the businessObjectDao.
 NotificationMessageDelivery getNotificationMessageDeliveryByDelivererId(String id)
          This method will retrieve a NotificationMessageDelivery object from the system, given the external deliverer system id registered with the NotificationMessageDelivery.
 Collection<NotificationMessageDelivery> takeMessageDeliveriesForAutoRemoval()
          This method is responsible for atomically finding all untaken message deliveries that are ready to be autoremoved, marking them as taken and returning them to the caller for processing.
 Collection<NotificationMessageDelivery> takeMessageDeliveriesForDispatch()
          This method is responsible for atomically finding all untaken, undelivered messagedeliveries, marking them as taken and returning them to the caller for processing.
 void unlockMessageDelivery(NotificationMessageDelivery messageDelivery)
          Unlocks the specified messageDelivery object
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NotificationMessageDeliveryServiceImpl

public NotificationMessageDeliveryServiceImpl(GenericDao businessObjectDao,
                                              NotificationMessegeDeliveryDao ntdDao)
Constructs a NotificationServiceImpl class instance.

Parameters:
businessObjectDao -
Method Detail

getNotificationMessageDelivery

public NotificationMessageDelivery getNotificationMessageDelivery(Long id)
This is the default implementation that uses the businessObjectDao.

Specified by:
getNotificationMessageDelivery in interface NotificationMessageDeliveryService
Parameters:
id -
Returns:
NotificationMessageDelivery

getNotificationMessageDeliveryByDelivererId

public NotificationMessageDelivery getNotificationMessageDeliveryByDelivererId(String id)
Description copied from interface: NotificationMessageDeliveryService
This method will retrieve a NotificationMessageDelivery object from the system, given the external deliverer system id registered with the NotificationMessageDelivery.

Specified by:
getNotificationMessageDeliveryByDelivererId in interface NotificationMessageDeliveryService
Parameters:
id - the external deliverer system id
Returns:
NotificationMessageDelivery
See Also:
NotificationMessageDeliveryService.getNotificationMessageDeliveryByDelivererId(java.lang.String)

getNotificationMessageDeliveries

public Collection<NotificationMessageDelivery> getNotificationMessageDeliveries()
Description copied from interface: NotificationMessageDeliveryService
This method will return all NotificationMessageDelivery objects in the system actual record.

Specified by:
getNotificationMessageDeliveries in interface NotificationMessageDeliveryService
Returns:
List list of NotificationMessageDelivery objects in the system
See Also:
NotificationMessageDeliveryService.getNotificationMessageDeliveries()

getNotificationMessageDeliveries

public Collection<NotificationMessageDelivery> getNotificationMessageDeliveries(NotificationBo notification,
                                                                                String userRecipientId)
Description copied from interface: NotificationMessageDeliveryService
This method will return all NotificationMessageDelievery objects generated for the given Notification for the given user

Specified by:
getNotificationMessageDeliveries in interface NotificationMessageDeliveryService
Parameters:
notification - the notification which generated the message deliveries
userRecipientId - the id of the user whose message deliveries to obtain
Returns:
collection of NotificationMessageDelivery objects generated for the given Notification for the given user
See Also:
org.kuali.rice.ken.service.NotificationMessageDeliveryService#getNotificationMessageDeliveries(java.lang.Long, java.lang.String)

takeMessageDeliveriesForDispatch

public Collection<NotificationMessageDelivery> takeMessageDeliveriesForDispatch()
This method is responsible for atomically finding all untaken, undelivered messagedeliveries, marking them as taken and returning them to the caller for processing. NOTE: it is important that this method execute in a SEPARATE dedicated transaction; either the caller should NOT be wrapped by Spring declarative transaction and this service should be wrapped (which is the case), or the caller should arrange to invoke this from within a newly created transaction).

Specified by:
takeMessageDeliveriesForDispatch in interface NotificationMessageDeliveryService
Returns:
a list of available message deliveries that have been marked as taken by the caller

takeMessageDeliveriesForAutoRemoval

public Collection<NotificationMessageDelivery> takeMessageDeliveriesForAutoRemoval()
This method is responsible for atomically finding all untaken message deliveries that are ready to be autoremoved, marking them as taken and returning them to the caller for processing. NOTE: it is important that this method execute in a SEPARATE dedicated transaction; either the caller should NOT be wrapped by Spring declarative transaction and this service should be wrapped (which is the case), or the caller should arrange to invoke this from within a newly created transaction).

Specified by:
takeMessageDeliveriesForAutoRemoval in interface NotificationMessageDeliveryService
Returns:
a list of notifications to be autoremoved that have been marked as taken by the caller

unlockMessageDelivery

public void unlockMessageDelivery(NotificationMessageDelivery messageDelivery)
Unlocks the specified messageDelivery object

Specified by:
unlockMessageDelivery in interface NotificationMessageDeliveryService
Parameters:
messageDelivery - the message delivery to unlock


Copyright © 2005-2012 The Kuali Foundation. All Rights Reserved.