1 /**
2 * Copyright 2005-2015 The Kuali Foundation
3 *
4 * Licensed under the Educational Community License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.opensource.org/licenses/ecl2.php
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16 package org.kuali.rice.kim.impl.group;
17
18 import org.kuali.rice.kim.impl.group.GroupBo;
19
20 import java.util.List;
21
22
23 /**
24 * Provides internal notification services for the GroupServiceImpl. It
25 * specifically allows GroupServiceImpl to notify interested parties that
26 * a group's membership has changed.
27 *
28 * @author Kuali Rice Team (rice.collab@kuali.org)
29 *
30 */
31 public interface GroupInternalService {
32 /**
33 * Save the GroupBo, being careful to reset the action document
34 * assignments based on any membership changes.
35 *
36 * @param group
37 */
38 public GroupBo saveWorkgroup(GroupBo group);
39
40 /**
41 * Updates KEW for workgroup members according to membership differences between the
42 * two workgroups. Since the changeset of such an operation could potentially be quite large,
43 * this method should schedule the changes to occur asynchronously to mitigate transaction
44 * and concurrent document modification issues.
45 */
46 public void updateForWorkgroupChange( String groupId,
47 List<String> oldPrincipalIds, List<String> newPrincipalIds);
48
49 /**
50 * Updates KEW for a the given document for a user who was added to a Group. This method will generate
51 * new action items for the requests on the document which are for the Group. This method will also verify that
52 * the user is, in fact, still a member of the Group at the time of the invocation of this method before
53 * generating the action items.
54 */
55 public void updateForUserAddedToGroup(String principalId, String groupId);
56
57 /**
58 * Updates KEW for a the given document for a user who was removed from a Group. This will delete
59 * any action items for the given user on the document which were sent to that user because they were a
60 * member of the Group. This method will also verify that the user is still no longer a member of the Group
61 * at the time of the method invocation before removing the action items.
62 */
63 public void updateForUserRemovedFromGroup(String principalId, String groupId);
64 }