Changeset 1757
- Timestamp:
- 05/08/09 12:05:02 (16 years ago)
- Location:
- trunk/sources
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Hive.Contracts/3.2/ApplicationConstants.cs
r1752 r1757 59 59 public static string RESPONSE_CLIENT_RESOURCE_NOT_FOUND = "Client.ResourceNotFound"; 60 60 public static string RESPONSE_CLIENT_PERMISSIONOWNER_DOESNT_EXIST = "Client.PermissionOwnerDoesntExist"; 61 public static string RESPONSE_CLIENT_GET_GROUPS_OF_CLIENT = "Get all groups of a client"; 61 62 62 63 public static string RESPONSE_COMMUNICATOR_HEARTBEAT_RECEIVED = "Communicator.HeardbeatReceived"; -
trunk/sources/HeuristicLab.Hive.Contracts/3.2/Interfaces/IClientManager.cs
r1449 r1757 41 41 ResponseList<ClientGroup> GetAllClientGroups(); 42 42 [OperationContract] 43 ResponseObject<List<ClientGroup>> GetAllGroupsOfResource(Guid resourceId); 44 [OperationContract] 43 45 Response AddClientGroup(ClientGroup clientGroup); 44 46 [OperationContract] -
trunk/sources/HeuristicLab.Hive.Server.Core/3.2/ClientManager.cs
r1633 r1757 221 221 } 222 222 } 223 224 public ResponseObject<List<ClientGroup>> GetAllGroupsOfResource(Guid resourceId) { 225 ISession session = factory.GetSessionForCurrentThread(); 226 227 try { 228 IClientGroupAdapter clientGroupAdapter = 229 session.GetDataAdapter<ClientGroup, IClientGroupAdapter>(); 230 IClientAdapter clientAdapter = 231 session.GetDataAdapter<ClientInfo, IClientAdapter>(); 232 233 ResponseObject<List<ClientGroup>> response = new ResponseObject<List<ClientGroup>>(); 234 235 ClientInfo client = clientAdapter.GetById(resourceId); 236 List<ClientGroup> groupsOfClient = new List<ClientGroup>(clientGroupAdapter.MemberOf(client)); 237 response.Obj = groupsOfClient; 238 response.Success = true; 239 response.StatusMessage = ApplicationConstants.RESPONSE_CLIENT_GET_GROUPS_OF_CLIENT; 240 241 return response; 242 } 243 finally { 244 if (session != null) 245 session.EndSession(); 246 } 247 } 248 223 249 #endregion 224 250 } -
trunk/sources/HeuristicLab.Hive.Server.Core/3.2/ServerConsoleFacade.cs
r1650 r1757 182 182 } 183 183 184 public ResponseObject<List<ClientGroup>> GetAllGroupsOfResource(Guid resourceId) { 185 return clientManager.GetAllGroupsOfResource(resourceId); 186 } 187 184 188 #endregion 185 186 189 } 187 190 }
Note: See TracChangeset
for help on using the changeset viewer.