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

Get IFileItems from plain java source file

  Hello. How can I get a IFileItem object for a certain source file from my repository? I'm looking for the solution into the api but I can't find out how to do that using the Java Plain Client Libraries. Thanks

0 votes



One answer

Permanent link
From your other other question, if you have the IShareable for the file, then <tt>IShareable.getVersionable(monitor)</tt> gives you an IVersionableHandle which can be passed to
<tt>IItemManager#fetchCompleteItem(IItemHandle, int, IProgressMonitor)</tt> to get the full IFileItem.

You can get an ITeamRepository using <tt>RepositoryUtils.getTeamRepository(sharingDescriptor)</tt>, and then <tt>ITeamRepository.itemManager()</tt> give you the item manager.

0 votes

Comments

Hey. I can't get the IShareable object. I get a null reference for it.

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: Jul 24 '12, 3:54 a.m.

Question was seen: 2,940 times

Last updated: Jul 25 '12, 3:07 p.m.

Confirmation Cancel Confirm