org.kuali.rice.kew.actionrequest.service
Interface ActionRequestService

All Known Implementing Classes:
ActionRequestServiceImpl

public interface ActionRequestService

Service to handle the building, sorting, saving, activating and deactivating of action request graphs. These lists are what determine role and delegation behaviors in graphs of action requests. Fetching that is being done is also taking into account the 'weight' of action request codes.

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

Method Summary
 void activateRequest(ActionRequestValue actionRequest)
           
 void activateRequest(ActionRequestValue actionRequest, ActivationContext activationContext)
           
 void activateRequest(ActionRequestValue actionRequest, boolean simulate)
           
 List activateRequestNoNotification(ActionRequestValue actionRequest, ActivationContext activationContext)
           
 List activateRequestNoNotification(ActionRequestValue actionRequest, boolean simulate)
           
 void activateRequests(Collection actionRequests)
           
 void activateRequests(Collection actionRequests, ActivationContext activationContext)
           
 void activateRequests(Collection actionRequests, boolean simulate)
           
 void alterActionRequested(List actionRequests, String actionRequestCd)
           
 void deactivateRequest(ActionTakenValue actionTaken, ActionRequestValue actionRequest)
           
 void deactivateRequest(ActionTakenValue actionTaken, ActionRequestValue actionRequest, ActivationContext activationContext)
           
 void deactivateRequest(ActionTakenValue actionTaken, ActionRequestValue actionRequest, boolean simulate)
           
 void deactivateRequests(ActionTakenValue actionTaken, List actionRequests)
           
 void deactivateRequests(ActionTakenValue actionTaken, List actionRequests, ActivationContext activationContext)
           
 void deactivateRequests(ActionTakenValue actionTaken, List actionRequests, boolean simulate)
           
 void deleteActionRequestGraph(ActionRequestValue actionRequest)
           
 void deleteByActionRequestId(Long actionRequestId)
           
 void deleteByDocumentId(String documentId)
           
 boolean doesPrincipalHaveRequest(String principalId, String documentId)
          Checks if the given user has any Action Requests on the given document.
 List<ActionRequestValue> filterActionRequestsByCode(List<ActionRequestValue> actionRequests, String principalId, List<String> principalGroupIds, String requestCode)
          Filters action requests based on if they occur after the given requestCode, and if they relate to the given principal
 List findActivatedByGroup(String groupId)
           
 List findAllActionRequestsByDocumentId(String documentId)
           
 List<ActionRequestValue> findAllPendingRequests(String documentId)
          Returns all pending requests for a given routing entity
 List findAllValidRequests(String principalId, Collection actionRequests, String requestCode)
           
 List findAllValidRequests(String principalId, String documentId, String requestCode)
           
 ActionRequestValue findByActionRequestId(Long actionRequestId)
           
 List findByDocumentIdIgnoreCurrentInd(String documentId)
           
 List<ActionRequestValue> findByStatusAndDocId(String statusCd, String documentId)
           
 Recipient findDelegator(ActionRequestValue actionRequest)
          Returns the closest delegator for the given ActionRequest
 Recipient findDelegator(List actionRequests)
          Returns the highest priority delegator in the list of action requests.
 ActionRequestValue findDelegatorRequest(ActionRequestValue actionRequest)
           
 List findPendingByActionRequestedAndDocId(String actionRequestedCdCd, String documentId)
           
 List findPendingByDoc(String documentId)
           
 List findPendingByDocIdAtOrBelowRouteLevel(String documentId, Integer routeLevel)
           
 List findPendingByDocRequestCdNodeName(String documentId, String requestCode, String nodeName)
           
 List findPendingByDocRequestCdRouteLevel(String documentId, String requestCode, Integer routeLevel)
           
 List findPendingRootRequestsByDocId(String documentId)
           
 List findPendingRootRequestsByDocIdAtOrBelowRouteLevel(String documentId, Integer routeLevel)
           
 List findPendingRootRequestsByDocIdAtRouteLevel(String documentId, Integer routeLevel)
           
 List<ActionRequestValue> findPendingRootRequestsByDocIdAtRouteNode(String documentId, Long nodeInstanceId)
           
 List findPendingRootRequestsByDocumentType(Long documentTypeId)
           
 List findRootRequestsByDocIdAtRouteNode(String documentId, Long nodeInstanceId)
           
 AttributeSet getActionsRequested(DocumentRouteHeaderValue routeHeader, String principalId, boolean completeAndApproveTheSame)
           
 List getDelegateRequests(ActionRequestValue actionRequest)
           
 List<String> getPrincipalIdsWithPendingActionRequestByActionRequestedAndDocId(String actionRequestedCd, String documentId)
          This method gets a list of ids of all principals who have a pending action request for a document.
 ActionRequestValue getRoot(ActionRequestValue actionRequest)
           
 List<ActionRequestValue> getRootRequests(Collection<ActionRequestValue> actionRequests)
           
 List getTopLevelRequests(ActionRequestValue actionRequest)
          If this is a role request, then this method returns a List of the action request for each recipient within the role.
 ActionRequestValue initializeActionRequestGraph(ActionRequestValue actionRequest, DocumentRouteHeaderValue document, RouteNodeInstance nodeInstance)
           
 boolean isDuplicateRequest(ActionRequestValue actionRequest)
           
 boolean isValidActionRequestCode(String actionRequestCode)
           
 void saveActionRequest(ActionRequestValue actionRequest)
           
 void updateActionRequestsForResponsibilityChange(Set<Long> responsibilityIds)
           
 void validateActionRequest(ActionRequestValue actionRequest)
           
 

Method Detail

initializeActionRequestGraph

ActionRequestValue initializeActionRequestGraph(ActionRequestValue actionRequest,
                                                DocumentRouteHeaderValue document,
                                                RouteNodeInstance nodeInstance)

deactivateRequest

void deactivateRequest(ActionTakenValue actionTaken,
                       ActionRequestValue actionRequest)

deactivateRequests

void deactivateRequests(ActionTakenValue actionTaken,
                        List actionRequests)

deactivateRequest

void deactivateRequest(ActionTakenValue actionTaken,
                       ActionRequestValue actionRequest,
                       boolean simulate)

deactivateRequest

void deactivateRequest(ActionTakenValue actionTaken,
                       ActionRequestValue actionRequest,
                       ActivationContext activationContext)

deactivateRequests

void deactivateRequests(ActionTakenValue actionTaken,
                        List actionRequests,
                        boolean simulate)

deactivateRequests

void deactivateRequests(ActionTakenValue actionTaken,
                        List actionRequests,
                        ActivationContext activationContext)

deleteActionRequestGraph

void deleteActionRequestGraph(ActionRequestValue actionRequest)

findAllValidRequests

List findAllValidRequests(String principalId,
                          String documentId,
                          String requestCode)

findAllValidRequests

List findAllValidRequests(String principalId,
                          Collection actionRequests,
                          String requestCode)

findPendingByDoc

List findPendingByDoc(String documentId)

saveActionRequest

void saveActionRequest(ActionRequestValue actionRequest)

activateRequest

void activateRequest(ActionRequestValue actionRequest)

activateRequest

void activateRequest(ActionRequestValue actionRequest,
                     boolean simulate)

activateRequest

void activateRequest(ActionRequestValue actionRequest,
                     ActivationContext activationContext)

activateRequests

void activateRequests(Collection actionRequests)

activateRequests

void activateRequests(Collection actionRequests,
                      boolean simulate)

activateRequests

void activateRequests(Collection actionRequests,
                      ActivationContext activationContext)

activateRequestNoNotification

List activateRequestNoNotification(ActionRequestValue actionRequest,
                                   boolean simulate)

activateRequestNoNotification

List activateRequestNoNotification(ActionRequestValue actionRequest,
                                   ActivationContext activationContext)

findByActionRequestId

ActionRequestValue findByActionRequestId(Long actionRequestId)

findPendingRootRequestsByDocId

List findPendingRootRequestsByDocId(String documentId)

findPendingRootRequestsByDocIdAtRouteLevel

List findPendingRootRequestsByDocIdAtRouteLevel(String documentId,
                                                Integer routeLevel)

findPendingByDocIdAtOrBelowRouteLevel

List findPendingByDocIdAtOrBelowRouteLevel(String documentId,
                                           Integer routeLevel)

findPendingRootRequestsByDocIdAtOrBelowRouteLevel

List findPendingRootRequestsByDocIdAtOrBelowRouteLevel(String documentId,
                                                       Integer routeLevel)

findPendingRootRequestsByDocumentType

List findPendingRootRequestsByDocumentType(Long documentTypeId)

findAllActionRequestsByDocumentId

List findAllActionRequestsByDocumentId(String documentId)

findPendingByActionRequestedAndDocId

List findPendingByActionRequestedAndDocId(String actionRequestedCdCd,
                                          String documentId)

getPrincipalIdsWithPendingActionRequestByActionRequestedAndDocId

List<String> getPrincipalIdsWithPendingActionRequestByActionRequestedAndDocId(String actionRequestedCd,
                                                                              String documentId)
This method gets a list of ids of all principals who have a pending action request for a document.

Parameters:
actionRequestedCd -
documentId -
Returns:

findByStatusAndDocId

List<ActionRequestValue> findByStatusAndDocId(String statusCd,
                                              String documentId)

alterActionRequested

void alterActionRequested(List actionRequests,
                          String actionRequestCd)

findByDocumentIdIgnoreCurrentInd

List findByDocumentIdIgnoreCurrentInd(String documentId)

findActivatedByGroup

List findActivatedByGroup(String groupId)

updateActionRequestsForResponsibilityChange

void updateActionRequestsForResponsibilityChange(Set<Long> responsibilityIds)

getRoot

ActionRequestValue getRoot(ActionRequestValue actionRequest)

getRootRequests

List<ActionRequestValue> getRootRequests(Collection<ActionRequestValue> actionRequests)

isDuplicateRequest

boolean isDuplicateRequest(ActionRequestValue actionRequest)

findPendingByDocRequestCdRouteLevel

List findPendingByDocRequestCdRouteLevel(String documentId,
                                         String requestCode,
                                         Integer routeLevel)

findPendingByDocRequestCdNodeName

List findPendingByDocRequestCdNodeName(String documentId,
                                       String requestCode,
                                       String nodeName)

findAllPendingRequests

List<ActionRequestValue> findAllPendingRequests(String documentId)
Returns all pending requests for a given routing entity

Parameters:
documentId - the id of the document header being routed
Returns:
a List of all pending ActionRequestValues for the document

filterActionRequestsByCode

List<ActionRequestValue> filterActionRequestsByCode(List<ActionRequestValue> actionRequests,
                                                    String principalId,
                                                    List<String> principalGroupIds,
                                                    String requestCode)
Filters action requests based on if they occur after the given requestCode, and if they relate to the given principal

Parameters:
actionRequests - the List of ActionRequestValues to filter
principalId - the id of the principal to find active requests for
principalGroupIds - List of group ids that the principal belongs to
requestCode - the request code for all ActionRequestValues to be after
Returns:
the filtered List of ActionRequestValues

findDelegator

Recipient findDelegator(List actionRequests)
Returns the highest priority delegator in the list of action requests.


findDelegator

Recipient findDelegator(ActionRequestValue actionRequest)
Returns the closest delegator for the given ActionRequest


findDelegatorRequest

ActionRequestValue findDelegatorRequest(ActionRequestValue actionRequest)

deleteByDocumentId

void deleteByDocumentId(String documentId)

deleteByActionRequestId

void deleteByActionRequestId(Long actionRequestId)

validateActionRequest

void validateActionRequest(ActionRequestValue actionRequest)

findPendingRootRequestsByDocIdAtRouteNode

List<ActionRequestValue> findPendingRootRequestsByDocIdAtRouteNode(String documentId,
                                                                   Long nodeInstanceId)

findRootRequestsByDocIdAtRouteNode

List findRootRequestsByDocIdAtRouteNode(String documentId,
                                        Long nodeInstanceId)

getDelegateRequests

List getDelegateRequests(ActionRequestValue actionRequest)

getTopLevelRequests

List getTopLevelRequests(ActionRequestValue actionRequest)
If this is a role request, then this method returns a List of the action request for each recipient within the role. Otherwise, it will return a List with just the original action request.


isValidActionRequestCode

boolean isValidActionRequestCode(String actionRequestCode)

doesPrincipalHaveRequest

boolean doesPrincipalHaveRequest(String principalId,
                                 String documentId)
Checks if the given user has any Action Requests on the given document.


getActionsRequested

AttributeSet getActionsRequested(DocumentRouteHeaderValue routeHeader,
                                 String principalId,
                                 boolean completeAndApproveTheSame)


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