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

how to change the component visibility using plain java api

Hello,

I create a component using the plain java api. The code looks like this:

IComponentHandle component = wm.createComponent("Component Name", TeamArea , monitor);
IComponentOpFactory componentOpFactory = workspace.componentOpFactory();
IComponentOp addComponentOp = componentOpFactory.addComponent(component, false);
workspace.applyComponentOperations(Collections.singletonList(addComponentOp), false, monitor);

The eclipse GUI allows me to change the visibility for my component. How can I change the component visibility in the plain java api?

Steffen 
 

0 votes


Accepted answer

Permanent link
Steffen, use

IWorkspaceManager wm = SCMPlatform.getWorkspaceManager(teamRepository);
wm.setComponentOwnerAndVisibility(comp, newOwner, newScope, progress)
Steffen Kriese 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,946

Question asked: May 13 '14, 2:50 a.m.

Question was seen: 3,525 times

Last updated: May 13 '14, 3:09 a.m.

Confirmation Cancel Confirm