Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

Changeing Baseline of Component.

Is there a class in the API which will change the baseline of a component within a stream?

0 votes



2 answers

Permanent link
IBaselineHandle baseline = (IBaselineHandle) it.next();
IBaseline baseline_comp = (IBaseline)repo.itemManager().fetchCompleteItem(baseline, IItemManager.DEFAULT, MONITOR);
IBaselineConnection baseConnection = wm.getBaselineConnection(baseline_comp,MONITOR);

// Replace Baseline
clone_stream.replaceComponent(component,baseConnection,false,true,MONITOR);

0 votes


Permanent link
See replaceComponent(IComponentHandle, IConnection, boolean, IProgressMonitor) on com.ibm.team.scm.client.IFlowNodeConnection.

IFlowNodeConnection is the supertype of IWorkspaceConnection, which represents a workspace or stream.

The 2nd arg, IConnection, should be an IBaselineConnection, which can be obtained via:
getBaselineConnection(IBaselineHandle, IProgressMonitor)
on IWorkspaceManager.

See also its findBaselines(IBaselineSearchCriteria, int, IProgressMonitor) method.

0 votes

Your answer

Register or log in to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details

Question asked: Apr 21 '10, 11:01 a.m.

Question was seen: 6,350 times

Last updated: Apr 21 '10, 11:01 a.m.

Confirmation Cancel Confirm