how to get the active project areas by java API
Accepted answer
From a plain java client you could do the following:
IProcessItemService service = (IProcessItemService) repository.getClientLibrary(IProcessItemService.class);
List<IProjectArea> activeProjectAreas = new ArrayList();
List<IProjectArea> allProjectAreas;
projectAreas = service.findAllProjectAreas(service.ALL_PROPERTIES,monitor);
for (Iterator<IProjectArea> iterator = projectAreas.iterator(); iterator.hasNext();) {
IProjectArea iProjectArea = iterator.next();
if (iProjectArea.isArchived()==false) {
activeProjectAreas.add(iProjectArea)
}
}
One other answer
Hi,
Could you please provide the api for the server side Participant to get the project areas..
this would be of great help.
Thanks
Comments
public void run(AdvisableOperation operation,
IProcessConfigurationElement participantConfig,
IParticipantInfoCollector collector, IProgressMonitor monitor)
throws TeamRepositoryException {
IProcessArea processArea = operation.getProcessArea();
iProjectAreaHandle = processArea.getProjectArea();
Comments
Martin Dam Pedersen
Nov 21 '12, 5:46 a.m.What is the context in which you are trying to get project areas(serverside advisor/contributor, plain java client application or something else) ?
Harish Raj
Nov 21 '12, 7:45 a.m.I was looking for plain java client only. Thank you.