Display elements associated to a Req [message #1826571] |
Mon, 27 April 2020 06:35  |
Eclipse User |
|
|
|
Hello everyone,
I try to list all the elements that are bounded to a requirement with an Incoming relation (I use the requirement VP) with M2Do.
So, starting from the requirement REQ, my command is :
{m:for relation | REQ.ownedRelations->filter(CapellaRequirements::CapellaIncomingRelation)}
I then wanted to display the name of the targeted elements with the simple command {relation.target.name}, but as the type of the 'target' element is Abstract Element, it does not have a 'name' attribute.
I then tried to 'force' the typing with a filter :
{relation.taget->filter( relation.target.eClass()).name} , but the validation file display the following error :
Expression "relation.target- >filter(relation.target.eClass()).name" is invalid: missing expression
What those this error means ? How do you think will be the good way to get the name of the elements targeted by the Incoming relation ?
regards,
|
|
|
|
|
|
Re: Display elements associated to a Req [message #1833583 is a reply to message #1826704] |
Mon, 19 October 2020 02:41  |
Eclipse User |
|
|
|
Hello Julien,
I am using Capella and M2Doc also to document traceability between architecture and requirements. I am happy about your question, as the command/query you use made my day. But in general:
Where can I find a basic instruction about query/aql commands? Or a view of the datamodel of M2Doc in order to build up the right aql querries?
E.g. I couldn't find a working query between architecture and requirements (RE VP) until I found your command 'ownedRelations' - I can not find the notation 'Owned relation' used inside capella,
[Updated on: Mon, 19 October 2020 02:42] by Moderator
|
|
|
Powered by
FUDForum. Page generated in 0.05068 seconds