Hi guys,
I started to play with Moose, because I need to analyze some code to detect some bad smells.
As I used Moose ** a long time ago ** I am bit confused (and also lost) with the way of using and manipulating the objects in the Moose panel. Just an example to explain what I need is that:
1- I loaded a package of Pharo (let's say Collections-Sequenceable) I can see all the information offered by the panel, but I would like to do is the following:
a) How can I access to the information of the model, for example, to manipulate the methods of the analyzed classes? In previous versions of Moose, we could do something like MooseManager currentModel, but I see that the design has changed drastically, and now I can not see how I can do it. I need specifically access to the info stored in the model.
b) I see that you are using pragmas to define how we calculate properties in each source code entity. For example in:
FAMIXMethod numberOfInvokedMethods <MSEProperty: #numberOfInvokedMethods type: #Number>
<MSEComment: 'Return a number corresponding to the number of invoked methods'> <derived>
^ self privateState propertyAt: #numberOfInvokedMethods ifAbsentPut: [self invokedMethods size]
I added a new property with the same structure, but when I analyzed again a previous application, my new property is not appearing in the list of properties for a method in Moose.
Should I call a special message, or make a class invoke another method to update the properties used to analyze the application?
I will appreciate a lot your help. Cheers, Gabi _______________________________________________ Moose-dev mailing list [hidden email] https://www.iam.unibe.ch/mailman/listinfo/moose-dev |
Hi,
On Mon, Mar 17, 2014 at 4:37 PM, Gabriela Arevalo (gmail) <[hidden email]> wrote:
Welcome back! :)
The corresponding to "MooseManager currentModel" is now "MooseModel root allModels first". However, you should not need to use this. Instead, once you have your hands on a model in the Moose Panel, you should simply switch to the last tab (with the [|] icon), and there self is your model. For example, if you need all methods, you should:
- type "self allMethods" - select all text - press Cmd+o (or right click and open) This should pop the list of all method to the right.
You probably need to reinitialize the meta descriptions. Programatically, you can just do: "MooseModel resetMeta". Or you can spawn the Meta Browser (from WorldMenu/Moose/Moose MetaBrowser) and then click on the refresh icon from the top right.
Let us know how it works. Cheers, Doru
"Every thing has its own flow"
_______________________________________________ Moose-dev mailing list [hidden email] https://www.iam.unibe.ch/mailman/listinfo/moose-dev |
Doru,
Thanks! Amazing how the concept of the implementation of Moose has changed :)
If you are working with Moose from a user-viewpoint, the way you suggest is good one to use Moose as a query-engine. But if you want to use the data or even the properties to calculate something (or even to build a tool on top of Moose), I think the panel of [|] seems not to be useful.
How do the other tools do? How does, such as Roassal, take the data coming from Moose? Cheers, Gabi _______________________________________________ Moose-dev mailing list [hidden email] https://www.iam.unibe.ch/mailman/listinfo/moose-dev |
> How do the other tools do? How does, such as Roassal, take the data coming from Moose?
Directly from the model. Some visualization are defined either on the class MooseModel, or on the class FAMIXClassGroup. Alexandre -- _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;: Alexandre Bergel http://www.bergel.eu ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;. _______________________________________________ Moose-dev mailing list [hidden email] https://www.iam.unibe.ch/mailman/listinfo/moose-dev |
In reply to this post by Gabriela Arevalo (gmail)-2
Hi Gabi,
On Mon, Mar 17, 2014 at 9:29 PM, Gabriela Arevalo (gmail) <[hidden email]> wrote:
I think we are facing a misunderstanding. The Moose Panel is like an inspector with some specific functionalities. Nothing more. Essentially, all real logic you see is part of the model objects. So, if you want to build your code, you just program against objects. That is all.
But, let's be concrete and work by example. What exactly would you like to achieve? Cheers, Doru
"Every thing has its own flow"
_______________________________________________ Moose-dev mailing list [hidden email] https://www.iam.unibe.ch/mailman/listinfo/moose-dev |
Free forum by Nabble | Edit this page |