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

How to get ProvisionFactory in plugin development

Hi,
I'm developing a pre-condition plugin to check the state of a change-set related work-item.
I've find out how to get the change-set (starting from delivery operation) and I need to use ChangeSetLinks.findLinks method to get the links.
This method requires a ProviderFactory object that I can't find out. I tried with ClientProviderFactory but I've got an error because "is not accessible due to restriction on required library com.ibm.team.scm.client_2.0.0.I200906081830.jar".
Is there another way to get it (maybe useful also for a server side plugin)??
Thanks for every answer.

0 votes



2 answers

Permanent link
Ok, I think I've found it.

Client Side:

ProviderFactory = (ProviderFactory) repository.getClientLibrary(ProviderFactory.class)

Sever Side:

ProviderFactory provider = getService(ProviderFactory.class)


Are these the correct way to do it?

0 votes


Permanent link

Sever Side:
ProviderFactory provider = getService(ProviderFactory.class)

This is not correct. In ServerRequireWorkItemAdvisor has been used ServerProviderFactory but this class does not seem to be avaible (because of a library limitation). How can I get it??

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,927

Question asked: Jul 07 '09, 10:54 a.m.

Question was seen: 6,528 times

Last updated: Jul 07 '09, 10:54 a.m.

Confirmation Cancel Confirm