Getting a change set for a stream and baseline with plain Java
Hi,
I'm trying to get all change sets for a specific component baseline in a defined stream, but I found no way to to it.
What I want to do:
I'm able to get all change sets for a component baseline, but then I've no idea, in which stream it is.
I'm able to get all change sets for a stream, but then I've no reference to the baseline.
For both I took the setContext function, but I suspect, that I can't use it two times, if I do it in the way below, the program only takes the last setContext criteria:
IChangeSetSearchCriteria changeSetSearchCriteria = IChangeSetSearchCriteria.FACTORY.newInstance();
changeSetSearchCriteria.setComponent(comps.get(j));
changeSetSearchCriteria.setContext(streamHandle);
changeSetSearchCriteria.setContext(baselineHandle);
List<IChangeSetHandle> changeSetHandles = wm.findChangeSets(changeSetSearchCriteria, IWorkspaceManager.MAX_QUERY_SIZE, null);
Do you have an idea, how to solve it?
Thanks in advance,
Lars
I'm trying to get all change sets for a specific component baseline in a defined stream, but I found no way to to it.
What I want to do:
- Going through a project area
- Get all streams (with some conditions...) and do for each stream:
-
Find a defined component inside this stream. If found ->
- Get all baselines of the component and do for each baselines:
- Look, if there is a specific change set in the baseline
I'm able to get all change sets for a component baseline, but then I've no idea, in which stream it is.
I'm able to get all change sets for a stream, but then I've no reference to the baseline.
For both I took the setContext function, but I suspect, that I can't use it two times, if I do it in the way below, the program only takes the last setContext criteria:
IChangeSetSearchCriteria changeSetSearchCriteria = IChangeSetSearchCriteria.FACTORY.newInstance();
changeSetSearchCriteria.setComponent(comps.get(j));
changeSetSearchCriteria.setContext(streamHandle);
changeSetSearchCriteria.setContext(baselineHandle);
List<IChangeSetHandle> changeSetHandles = wm.findChangeSets(changeSetSearchCriteria, IWorkspaceManager.MAX_QUERY_SIZE, null);
Do you have an idea, how to solve it?
Thanks in advance,
Lars
Comments
Ralph Schoon
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER Nov 20 '13, 3:12 a.m.You might find examples for some of your questions in https://rsjazz.wordpress.com/2013/09/24/managing-workspaces-streams-and-components-using-the-plain-java-client-libraries/ and the related posts.