View Javadoc

1   /*
2    * <cvs:source>$Source: /devel/astrogrid/community/common/src/java/org/astrogrid/community/common/policy/manager/GroupManager.java,v $</cvs:source>
3    * <cvs:author>$Author: jdt $</cvs:author>
4    * <cvs:date>$Date: 2004/11/22 13:03:04 $</cvs:date>
5    * <cvs:version>$Revision: 1.9 $</cvs:version>
6    *
7    * <cvs:log>
8    *   $Log: GroupManager.java,v $
9    *   Revision 1.9  2004/11/22 13:03:04  jdt
10   *   Merges from Comm_KMB_585
11   *
12   *   Revision 1.8.104.1  2004/11/05 08:55:49  KevinBenson
13   *   Moved the GroupMember out of PolicyManager in the commons and client section.
14   *   Added more unit tests for GroupMember and PermissionManager for testing.
15   *   Still have some errors that needs some fixing.
16   *
17   *   Revision 1.8  2004/06/18 13:45:20  dave
18   *   Merged development branch, dave-dev-200406081614, into HEAD
19   *
20   *   Revision 1.7.36.1  2004/06/17 13:38:59  dave
21   *   Tidied up old CVS log entries
22   *
23   * </cvs:log>
24   *
25   */
26  package org.astrogrid.community.common.policy.manager ;
27  
28  import java.rmi.Remote ;
29  import java.rmi.RemoteException ;
30  
31  import org.astrogrid.community.common.policy.data.GroupData ;
32  import org.astrogrid.community.common.service.CommunityService ;
33  
34  import org.astrogrid.community.common.exception.CommunityPolicyException     ;
35  import org.astrogrid.community.common.exception.CommunityServiceException    ;
36  import org.astrogrid.community.common.exception.CommunityIdentifierException ;
37  
38  /***
39   * Public interface to our GroupManager service.
40   *
41   */
42  public interface GroupManager
43      extends Remote, CommunityService
44      {
45  
46      /***
47       * Add a new Group, given the Group ident.
48       * @param  ident The Group identifier.
49       * @return A GroupData for the Group.
50       * @throws CommunityIdentifierException If the identifier is not valid.
51       * @throws CommunityPolicyException If the identifier is already in the database.
52       * @throws CommunityServiceException If there is an internal error in the service.
53       * @throws RemoteException If the WebService call fails.
54       *
55       */
56      public GroupData addGroup(String ident)
57          throws RemoteException, CommunityServiceException, CommunityIdentifierException, CommunityPolicyException ;
58  
59      /***
60       * Add a new Group, given the Group data.
61       * @param  group The GroupData to add.
62       * @return A new GroupData for the Group.
63       * @throws CommunityIdentifierException If the identifier is not valid.
64       * @throws CommunityPolicyException If the identifier is already in the database.
65       * @throws CommunityServiceException If there is an internal error in the service.
66       * @throws RemoteException If the WebService call fails.
67       *
68       */
69      public GroupData addGroup(GroupData account)
70          throws RemoteException, CommunityServiceException, CommunityIdentifierException, CommunityPolicyException ;
71  
72      /***
73       * Request a Group details, given the Group ident.
74       * @param  ident The Group identifier.
75       * @return A GroupData for the Group.
76       * @throws CommunityIdentifierException If the identifier is not valid.
77       * @throws CommunityPolicyException If the identifier is not in the database.
78       * @throws CommunityServiceException If there is an internal error in the service.
79       * @throws RemoteException If the WebService call fails.
80       *
81       */
82      public GroupData getGroup(String ident)
83          throws RemoteException, CommunityServiceException, CommunityIdentifierException, CommunityPolicyException ;
84  
85      /***
86       * Update a Group.
87       * @param  group The new GroupData to update.
88       * @return A new GroupData for the Group.
89       * @throws CommunityIdentifierException If the identifier is not valid.
90       * @throws CommunityPolicyException If the identifier is not in the database.
91       * @throws CommunityServiceException If there is an internal error in the service.
92       * @throws RemoteException If the WebService call fails.
93       *
94       */
95      public GroupData setGroup(GroupData account)
96          throws RemoteException, CommunityServiceException, CommunityIdentifierException, CommunityPolicyException ;
97  
98      /***
99       * Delete a Group.
100      * @param  ident The Group identifier.
101      * @return The GroupData for the old Group.
102      * @throws CommunityIdentifierException If the identifier is not valid.
103      * @throws CommunityPolicyException If the identifier is not in the database.
104      * @throws CommunityServiceException If there is an internal error in the service.
105      * @throws RemoteException If the WebService call fails.
106      *
107      */
108     public GroupData delGroup(String ident)
109         throws RemoteException, CommunityServiceException, CommunityIdentifierException, CommunityPolicyException ;
110 
111     /***
112      * Request a list of local Groups.
113      * @return An array of GroupData objects.
114      * @throws CommunityServiceException If there is an internal error in the service.
115      * @throws RemoteException If the WebService call fails.
116      *
117      */
118     public Object[] getLocalGroups()
119         throws RemoteException, CommunityServiceException ;
120 
121     /***
122      * Request a list of local Groups that an Account belongs to, given the Account ident.
123      * @param  account The Account ifentifier.
124      * @return An array of GroupData objects.
125      * @throws CommunityServiceException If there is an internal error in the service.
126      * @throws RemoteException If the WebService call fails.
127      *
128      */
129     public Object[] getLocalAccountGroups(String account)
130         throws RemoteException, CommunityServiceException, CommunityIdentifierException ;    
131 
132     }