It's all about the answers!

Ask a question

Is there any way to get the name of the Shape (Artifact Type) in RRC from Shape URI ?


Samanwita Majumdar (5033940) | asked Sep 11 '12, 8:22 a.m.
We have obtained the shape URI through and it returns a URI as Resource Shape URI->> https://ch5dlfi077.in.ibm.com:9445/rm/types/_p1fzIvcNEeGlgZR4QWph9g, is there any way by which we can get the name of the shape?

The code snippet I am using to get the shape is as follows..

NodeList paNode = (NodeList)(xpath.evaluate(requirementfactoryShapes, doc, XPathConstants.NODESET));
        for (int i = 0; i < paNode.getLength(); i++) {
            //These all correspond to an artifact type URI in RRC
            System.out.println("Resource Shape URI->> " + paNode.item(i).getTextContent());
      
        }
       

3 answers



permanent link
Gabriel Ruelas (1.1k13) | answered Sep 11 '12, 10:51 a.m.
Hi,
The name of the shape is exposed in the response as :

<dc:title rdf:parseType="Literal">Feature</dc:title>

It is not part of a property within the response, it is an attribute of it.

permanent link
liesa pugsley (311) | answered Oct 19 '12, 12:22 a.m.
Is it possible to use the resource shape (ie requirement type) in the querycapabilityURI -so that I could select all requirements that were 'Business Requirement' artifact type?

permanent link
Gabriel Ruelas (1.1k13) | answered Oct 22 '12, 10:05 a.m.
Yes. but it must be specified as rm:ofType.

Here is an example :
"....   &oslc.where=rm:ofType=<https://grarrc.ibm.com:9443/rm/types/_SAwm2t5jEeGb6IIbvOh9Dw>   ...."

Your answer


Register or 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.