org.kuali.rice.ken.postprocessor.kew
Class NotificationSenderFormPostProcessor

java.lang.Object
  extended by org.kuali.rice.ken.postprocessor.kew.NotificationSenderFormPostProcessor
All Implemented Interfaces:
PostProcessorRemote

public class NotificationSenderFormPostProcessor
extends Object
implements PostProcessorRemote

This class is the post processor that gets run when the general notification message sending form is approved by its reviewers.

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

Field Summary
(package private)  GenericDao businessObjectDao
           
private static org.apache.log4j.Logger LOG
           
(package private)  NotificationMessageContentService messageContentService
           
(package private)  NotificationService notificationService
           
 
Constructor Summary
NotificationSenderFormPostProcessor()
          Constructs a NotificationSenderFormPostProcessor instance.
NotificationSenderFormPostProcessor(NotificationService notificationService, GenericDao businessObjectDao)
          Constructs a NotificationSenderFormPostProcessor instance.
 
Method Summary
 boolean afterProcess(AfterProcessEventDTO afterProcessEvent)
          The document has just completed processing by the Workflow engine.
 boolean beforeProcess(BeforeProcessEventDTO beforeProcessEvent)
          The document is about to be processed by the Workflow engine.
 boolean doActionTaken(ActionTakenEventDTO arg0)
          KEW is signaling that the document has had an action taken on it by a user
 boolean doDeleteRouteHeader(DeleteEventDTO arg0)
          KEW is signaling that the document should be deleted.
 boolean doRouteLevelChange(DocumentRouteLevelChangeDTO arg0)
          The document has changed route level.
 boolean doRouteStatusChange(DocumentRouteStatusChangeDTO arg0)
          When the EDL simple message sending form is submitted, it is routed straight to FINAL and at that time (when RESOLVED), we actually send the notification.
 String[] getDocumentIdsToLock(DocumentLockingEventDTO documentLockingEvent)
          Executed prior to document locking in the workflow engine.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOG

private static final org.apache.log4j.Logger LOG

notificationService

NotificationService notificationService

businessObjectDao

GenericDao businessObjectDao

messageContentService

NotificationMessageContentService messageContentService
Constructor Detail

NotificationSenderFormPostProcessor

public NotificationSenderFormPostProcessor()
Constructs a NotificationSenderFormPostProcessor instance.


NotificationSenderFormPostProcessor

public NotificationSenderFormPostProcessor(NotificationService notificationService,
                                           GenericDao businessObjectDao)
Constructs a NotificationSenderFormPostProcessor instance.

Parameters:
notificationService -
businessObjectDao -
Method Detail

doActionTaken

public boolean doActionTaken(ActionTakenEventDTO arg0)
                      throws RemoteException
Description copied from interface: PostProcessorRemote
KEW is signaling that the document has had an action taken on it by a user

Specified by:
doActionTaken in interface PostProcessorRemote
Returns:
Throws:
RemoteException
See Also:
PostProcessorRemote.doActionTaken(org.kuali.rice.kew.dto.ActionTakenEventDTO)

doDeleteRouteHeader

public boolean doDeleteRouteHeader(DeleteEventDTO arg0)
                            throws RemoteException
Description copied from interface: PostProcessorRemote
KEW is signaling that the document should be deleted. The application can reject this by returning false. If an Exception is thrown the docuemnt will go to exception routing. If a ResourceUnavailableException is thrown, the doc will be requeued and will try again later to delete the document.

Specified by:
doDeleteRouteHeader in interface PostProcessorRemote
Returns:
Throws:
RemoteException
See Also:
PostProcessorRemote.doDeleteRouteHeader(org.kuali.rice.kew.dto.DeleteEventDTO)

doRouteLevelChange

public boolean doRouteLevelChange(DocumentRouteLevelChangeDTO arg0)
                           throws RemoteException
Description copied from interface: PostProcessorRemote
The document has changed route level. The docEvent contains the information about the change. This method should do what ever is appropriate for various route level changes to a document. The method should return true if the change is correct and all application actions as a result of the change are successful. It should return false if the application considers this an incorrect change. The method can throw a ResourceUnavailableException in order to requeue the document and try again later.

Specified by:
doRouteLevelChange in interface PostProcessorRemote
Returns:
true if the status change is correct and application actions are successful
Throws:
RemoteException
See Also:
PostProcessorRemote.doRouteLevelChange(org.kuali.rice.kew.dto.DocumentRouteLevelChangeDTO)

doRouteStatusChange

public boolean doRouteStatusChange(DocumentRouteStatusChangeDTO arg0)
                            throws RemoteException
When the EDL simple message sending form is submitted, it is routed straight to FINAL and at that time (when RESOLVED), we actually send the notification.

Specified by:
doRouteStatusChange in interface PostProcessorRemote
Returns:
true if the status change is correct and application actions are successful later if this exception is thrown
Throws:
RemoteException
See Also:
PostProcessorRemote.doRouteStatusChange(org.kuali.rice.kew.dto.DocumentRouteStatusChangeDTO)

beforeProcess

public boolean beforeProcess(BeforeProcessEventDTO beforeProcessEvent)
                      throws Exception
Description copied from interface: PostProcessorRemote
The document is about to be processed by the Workflow engine.

Specified by:
beforeProcess in interface PostProcessorRemote
Parameters:
beforeProcessEvent - - holder for data from the engine's process
Returns:
true if the method is successful, false otherwise
Throws:
Exception - A general Exception will put the document into Exception routing
See Also:
PostProcessorRemote.beforeProcess(org.kuali.rice.kew.dto.BeforeProcessEventDTO)

afterProcess

public boolean afterProcess(AfterProcessEventDTO afterProcessEvent)
                     throws Exception
Description copied from interface: PostProcessorRemote
The document has just completed processing by the Workflow engine.

Specified by:
afterProcess in interface PostProcessorRemote
Parameters:
afterProcessEvent - - holder for data from the engine's process including whether the engine was successful or not
Returns:
true if the method is successful, false otherwise
Throws:
Exception - A general Exception will put the document into Exception routing
See Also:
PostProcessorRemote.afterProcess(org.kuali.rice.kew.dto.AfterProcessEventDTO)

getDocumentIdsToLock

public String[] getDocumentIdsToLock(DocumentLockingEventDTO documentLockingEvent)
                              throws Exception
Description copied from interface: PostProcessorRemote
Executed prior to document locking in the workflow engine. This method returns an array of document ids to lock prior to execution of the document in the workflow engine. If the engine processing is going to result in updates to any other documents, they should be locked at the beginning of the engine processing transaction. This method facilitates that.

Note that, by default, the id of the document that is being processed by the engine is always locked. So there is no need to return that document id in the array of document ids to lock.

Specified by:
getDocumentIdsToLock in interface PostProcessorRemote
Returns:
an array of document ids to lock prior to execution of the workflow engine
Throws:
Exception
See Also:
PostProcessorRemote.getDocumentIdsToLock(org.kuali.rice.kew.dto.DocumentLockingEventDTO)


Copyright © 2004-2011 The Kuali Foundation. All Rights Reserved.