001: /*
002: * Copyright 2005-2006 The Kuali Foundation.
003: *
004: *
005: * Licensed under the Educational Community License, Version 1.0 (the "License");
006: * you may not use this file except in compliance with the License.
007: * You may obtain a copy of the License at
008: *
009: * http://www.opensource.org/licenses/ecl1.php
010: *
011: * Unless required by applicable law or agreed to in writing, software
012: * distributed under the License is distributed on an "AS IS" BASIS,
013: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
014: * See the License for the specific language governing permissions and
015: * limitations under the License.
016: */
017: package edu.iu.uis.eden.actionlist;
018:
019: import java.util.Collection;
020: import java.util.List;
021:
022: import edu.iu.uis.eden.actionitem.ActionItem;
023: import edu.iu.uis.eden.actionrequests.ActionRequestValue;
024: import edu.iu.uis.eden.exception.EdenUserNotFoundException;
025: import edu.iu.uis.eden.user.WorkflowUser;
026: import edu.iu.uis.eden.workgroup.Workgroup;
027:
028: /**
029: * Main service for doing action list data access work
030: *
031: * @author ewestfal
032: * @author rkirkend
033: *
034: */
035: public interface ActionListService {
036:
037: public Collection getActionList(WorkflowUser workflowUser,
038: ActionListFilter filter);
039:
040: public Collection findUserDelegators(WorkflowUser workflowUser,
041: String delegationType) throws EdenUserNotFoundException;
042:
043: public boolean refreshActionList(WorkflowUser user);
044:
045: public void saveActionItem(ActionItem actionItem)
046: throws EdenUserNotFoundException;
047:
048: public void deleteActionItem(ActionItem actionItem);
049:
050: public void deleteByRouteHeaderId(Long routeHeaderId);
051:
052: public void deleteActionItems(Long actionRequestId);
053:
054: public List generateActionItems(ActionRequestValue actionRequest,
055: boolean simulate) throws EdenUserNotFoundException;
056:
057: public Collection findByWorkflowUser(WorkflowUser workflowUser);
058:
059: // public Collection findByWorkgroupId(Long workgroupId);
060:
061: public Collection findByWorkflowUserRouteHeaderId(
062: String workflowUserId, Long routeHeaderId);
063:
064: public Collection findByRouteHeaderId(Long routeHeaderId);
065:
066: /**
067: * Updates ActionItems for workgroup members according to membership differences between the
068: * twho workgroups. Since the changeset of such an operation could potentially be quite large,
069: * this method should schedule the changes to occur asynchronously to mitigate transaction
070: * and concurent document modification issues.
071: */
072: public void updateActionItemsForWorkgroupChange(
073: Workgroup oldWorkgroup, Workgroup newWorkgroup)
074: throws EdenUserNotFoundException;
075:
076: /**
077: * Updates the action list for a the given document for a user who was added to a workgroup. This method will generate
078: * new action items for the requests on the document which are for the workgroup. This method will also verify that
079: * the user is, in fact, still a member of the workgroup at the time of the invocation of this method before
080: * generating the action items.
081: */
082: public void updateActionListForUserAddedToWorkgroup(
083: WorkflowUser user, Workgroup workgroup)
084: throws EdenUserNotFoundException;
085:
086: /**
087: * Updates the action list for a the given document for a user who was removed from a workgroup. This will delete
088: * any action items for the given user on the document which were sent to that user because they were a
089: * member of the workgroup. This method will also verify that the user is still no longer a member of the workgroup
090: * at the time of the method invocation before removing the action items.
091: */
092: public void updateActionListForUserRemovedFromWorkgroup(
093: WorkflowUser user, Workgroup workgroup)
094: throws EdenUserNotFoundException;
095:
096: public void updateActionItemsForTitleChange(Long routeHeaderId,
097: String newTitle) throws EdenUserNotFoundException;
098:
099: public Collection findDelegators(WorkflowUser user,
100: String delegationType) throws EdenUserNotFoundException;
101:
102: public void validateActionItem(ActionItem actionItem);
103:
104: public ActionItem findByActionItemId(Long actionItemId);
105:
106: }
|