It's all about the answers!

Ask a question

Retrieve IChangeSet by changeSetItemId


Lee John (51310) | asked Apr 02 '15, 2:44 a.m.
 As title, if I know that "changeSetItemId=_kpercZeHEeSI854Fc8OZ_A", how do I retrieve the corresponding IChangeSet by this information?

Accepted answer


permanent link
Ralph Schoon (62.3k33643) | answered Apr 02 '15, 3:07 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
As described in https://rsjazz.wordpress.com/2013/03/20/understanding-and-using-the-rtc-java-client-api/ section UUID's, you create a handle from the UUID and then you use the normal search/resolve mechanism to get the object.
Lee John selected this answer as the correct answer

Comments
Lee John commented Apr 02 '15, 3:41 a.m. | edited Apr 02 '15, 3:42 a.m.

 Working code snippet:

String uuid = "_kpercZeHEeSI854Fc8OZ_A";
// IItemHandle handle = [itemtype].ITEM_TYPE.createItemHandle(UUID.valueOf(uuid_string), null);
IChangeSetHandle changeSetHandle=(IChangeSetHandle)IChangeSet.ITEM_TYPE.createItemHandle(UUID.valueOf(uuid), null);
IChangeSet changeset = (IChangeSet) TeamRepository.itemManager()
.fetchCompleteItem(changeSetHandle, IItemManager.DEFAULT,
null);

Your answer


Register or to post your answer.