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

Is it possible to get the project area from build result UUID?

Now I have build result UUID in string format and want to get the associated project area. Is it possible?

Here's the code I have

UUID id = UUID.valueOf("_TV2EEcMDEeS4Jobxo3QE1w");
IBuildResultHandle buildResultHandle = (IBuildResultHandle) IBuildResult.ITEM_TYPE.createItemHandle(id, null);
IBuildResult buildResult = (IBuildResult) repo.itemManager().fetchCompleteItem(buildResultHandle, ItemManager.DEFAULT, monitor);

0 votes


Accepted answer

Permanent link
From the build result, get the build definition. From the build definition get the process area and from that get the Project area.

              IBuildDefinition bHandle = buildResult.getBuildDefinition()
              IBuildDefinition bDef = resolve bHandle
              bDef.getProcessArea()

Stephen Lai selected this answer as the correct answer

0 votes

Comments

Big thanks, Ralph! It works!

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

Question asked: Apr 02 '15, 4:55 a.m.

Question was seen: 2,678 times

Last updated: Apr 02 '15, 6:42 a.m.

Confirmation Cancel Confirm