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

How to check if the particular changeset is part of a given snapshot in RTC SCM programatically.

Hello All,

I have a usecase wherein i need to search for a CS.
I have a Snapshot URI and a CS UUID, Is there any way that i can locate/find this CS ?

Are there any APIs to do this ?

Request you to assist on this. Thankyou.

0 votes


Accepted answer

Permanent link
If you are writing client-side code, the API to use is in IWorkspaceManager:
   List<ILocateChangeSetsSearchResult> locateChangeSets(ILocateChangeSetsSearchCriteria scope, IProgressMonitor monitor)

If you are writing server-side code, the API to use is in IScmQueryService:
   ILocateChangeSetsSearchResult[] findLocateChangeSets(ILocateChangeSetsSearchCriteria scope, IRepositoryProgressMonitorHandle repoMonitor)

You pass in the IChangeSetHandle and the IBaselineSetHandle (snapshot) to the ILocateChangeSetsSearchCriteria.

If the change set exists in the snapshot, then ILocateChangeSetsSearchResult.getSnapshots() will contain the snapshot passed in (otherwise the list will be empty)

Jazzuser user selected this answer as the correct answer

1 vote

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

Question asked: Jul 11 '18, 6:57 a.m.

Question was seen: 1,938 times

Last updated: Jul 11 '18, 10:09 a.m.

Confirmation Cancel Confirm