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

How to create a stream from a snapshot programatically?

hello team

I am trying to create a new Stream using snapshot. The following code executes without any error. It created the stream but there is no component or snapshot associated with the stream.

part of the code snippet:

stream = manager.createStream(project, streamName, description, monitor);
stream.addBaselineSet(ibaselineset, monitor);

 Any help is appreciated.

0 votes

Comments


Accepted answer

Permanent link

After creating a new snapshot, you can use IComponentOpFactory.addComponent(...), and seed it with the BaselineConnection. You would do this for each baseline in the Snapshot. When done use IWorkspaceConnection#applyComponentOperations(...)

Ralph Schoon selected this answer as the correct answer

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
× 10,941
× 1,202

Question asked: May 30 '17, 10:03 a.m.

Question was seen: 2,145 times

Last updated: Jan 11 '19, 4:14 p.m.

Confirmation Cancel Confirm