1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30 package org.astrogrid.community.common.policy.manager ;
31
32 import java.rmi.Remote ;
33 import java.rmi.RemoteException ;
34
35 import org.astrogrid.community.common.policy.data.GroupMemberData ;
36 import org.astrogrid.community.common.service.CommunityService ;
37
38 import org.astrogrid.community.common.exception.CommunityPolicyException ;
39 import org.astrogrid.community.common.exception.CommunityServiceException ;
40 import org.astrogrid.community.common.exception.CommunityIdentifierException ;
41
42 /***
43 * Public interface to our GroupManager service.
44 *
45 */
46 public interface GroupMemberManager
47 extends Remote, CommunityService
48 {
49
50 /***
51 * Add an Account to a Group.
52 * The group must be local, but Account can be local or remote.
53 * @param account The Account identifier.
54 * @param group The Group identifier.
55 * @return A GroupMemberData to confirm the membership.
56 * @throws CommunityIdentifierException If one of the identifiers is not valid.
57 * @throws CommunityPolicyException If one the identifiers is not in the database.
58 * @throws CommunityServiceException If there is an internal error in the service.
59 * @throws RemoteException If the Group is in a remote Community and the WebService call fails.
60 *
61 */
62 public GroupMemberData addGroupMember(String account, String group)
63 throws RemoteException, CommunityServiceException, CommunityIdentifierException, CommunityPolicyException ;
64
65 /***
66 * Remove an Account from a Group.
67 * The group must be local, but Account can be local or remote.
68 * @param account The Account identifier.
69 * @param group The Group identifier.
70 * @return A GroupMemberData to confirm the membership.
71 * @throws CommunityIdentifierException If one of the identifiers is not valid.
72 * @throws CommunityPolicyException If one the identifiers is not in the database.
73 * @throws CommunityServiceException If there is an internal error in the service.
74 * @throws RemoteException If the Group is in a remote Community and the WebService call fails.
75 *
76 */
77 public GroupMemberData delGroupMember(String account, String group)
78 throws RemoteException, CommunityServiceException, CommunityPolicyException, CommunityIdentifierException ;
79
80 /***
81 * Request a list of Group members.
82 * The group must be local.
83 * @param group The Group identifier.
84 * @return An array of GroupMemberData objects..
85 * @throws CommunityIdentifierException If one of the identifiers is not valid.
86 * @throws CommunityPolicyException If one the identifiers is not in the database.
87 * @throws CommunityServiceException If there is an internal error in the service.
88 * @throws RemoteException If the Group is in a remote Community and the WebService call fails.
89 *
90 */
91 public Object[] getGroupMembers(String group)
92 throws RemoteException, CommunityServiceException, CommunityPolicyException, CommunityIdentifierException ;
93
94 /***
95 * Request a list of Group members.
96 * The group must be local.
97 * @param group The Group identifier.
98 * @return An array of GroupMemberData objects..
99 * @throws CommunityIdentifierException If one of the identifiers is not valid.
100 * @throws CommunityPolicyException If one the identifiers is not in the database.
101 * @throws CommunityServiceException If there is an internal error in the service.
102 * @throws RemoteException If the Group is in a remote Community and the WebService call fails.
103 *
104 */
105 public Object[] getGroupMembers()
106 throws RemoteException, CommunityServiceException, CommunityPolicyException, CommunityIdentifierException ;
107
108
109 /***
110 * Request a list of Group members.
111 * The group must be local.
112 * @param group The Group identifier.
113 * @return An array of GroupMemberData objects..
114 * @throws CommunityIdentifierException If one of the identifiers is not valid.
115 * @throws CommunityPolicyException If one the identifiers is not in the database.
116 * @throws CommunityServiceException If there is an internal error in the service.
117 * @throws RemoteException If the Group is in a remote Community and the WebService call fails.
118 *
119 */
120 public GroupMemberData getGroupMember(String account, String group)
121 throws RemoteException, CommunityServiceException, CommunityPolicyException, CommunityIdentifierException ;
122
123 }