Is there a way in the Q language that I can search through a model and create a list of all Operations, ensuring that there are no duplicates, and then print it later? As kind of a pseudo-example:
Recurse through Model;
if ($metaClass = "Operation") && (match($name, ListOfOperations) =
then ListOfOperations = ListOfOperations + $name;
End Recurse through Model;
Is it possible to also store the information on the operation (description, return, arguments, etc)?
I'm new to ReporterPlus and the lack of documentation/examples for the Q language is frustrating. Thanks for any help ...
Pinned topic Saving information for later printing in ReporterPlus
Answered question This question has been answered.
Unanswered question This question has not been answered yet.
Updated on 2012-10-18T16:03:39Z at 2012-10-18T16:03:39Z by Champagne
Champagne 2700027YW642 Posts
Re: Saving information for later printing in ReporterPlus2012-10-18T16:03:39ZThis is the accepted answer. This is the accepted answer.Hi I don't know if you've found the solution to this yet.
To get all the operations you can just add a new node to your report and on the iteration tab check the "Iterates" checkbox, for the iteration type select "Class" now you can choose Operation metaclass from the combo box and the report will iterate through all the operations in the model.
This does a similar thing to the Q language command all.
In Q to get a collection of all the operations use the following
The iteration loops through these objects and so you can access any of the attributes you have set on those objects.
There will be no duplications in either of these it will be a simple collection of all the artifacts in the model based on the Operation metaClass.
Shortly after that you'll get frustrated over the limitations of Q and reporterPLUS, having said that you can achieve some really stunning results within those limitations.
If you have a specific problem or relationship you are after then just reply, ReporterPLUS can be a little bit of a black art but we love it really (well sort of).