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

How to retrieve the "Used in" information of a requirement artifact with client extension?

In the documentation for RM client extensions (https://jazz.net/wiki/bin/view/Main/RMExtensionsAPI502) I found under  "Well known attributes and properties"

CONTAINING_MODULE  = The Used In property of an artifact that refers to a containing module

I expected to get the references as displayed in the "Where Used" section of the artifact.

the code looks like this

RM.Data.getAttributes(refs,  [RM.Data.Attributes.IDENTIFIER, RM.Data.Attributes.CONTAINING_MODULE], function(opResult) {
   if (opResult.code === RM.OperationResult.OPERATION_OK) {
        opResult.data.forEach(function(item){
        var id = item.values[RM.Data.Attributes.IDENTIFIER];
        var used = item.values[RM.Data.Attributes.CONTAINING_MODULE];
        });
});

The "id" is ok. For "used" I always get the value "undefined".

What is wrong?

0 votes

Comments

Hi,

Did you find an answer to this? I am trying to do the same thing. I get used populated but it looks like it is with an empty object. (I am using 5.0.1)

Not really ... the only thing I recognized: if I run the extension from within a module, it returns the the current module !?

1 vote


Accepted answer

Permanent link
From memory it appears that the containing module can ONLY be used when the module is opened and not when you browse artefacts. This is a pretty big limitation however it does work when the module is open.
Hutter Donat selected this answer as the correct answer

0 votes


2 other answers

Permanent link
Thanks for the clarification ... I assumed that the CONTAINING_MODULE was returning the "Where used" section, which is definitely not the case.

0 votes


Permanent link
I believe this question has been answered. If not, please add another comment.

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

Question asked: Jan 12 '15, 12:17 p.m.

Question was seen: 5,854 times

Last updated: Mar 02 '21, 2:10 a.m.

Confirmation Cancel Confirm