We have
MooseElement defines the minimal interface of an entity
Proposition:
MooseElement defines the minimal interface of an entity: any moose entity should answer its mooseID, its mooseName and its mooseModel.
A mooseID is an Integer that uniquely identifies this entity within the entire Moose environment.
It should not change nor be nil.
The mooseModel of an entity is must be an instance of MooseModel. It may be nil if the entity is not part of a model.
Each entity belongs to one and only one model, if an entity has not yet been added to a model or if an entity has been removed from a model
the mooseModel is undefined, that is it may be nil.
An entity mooseName result a string version of the mooseID.
Please comment.
Stef
Hi
I clicked on AllModel classes
click on one entity (a Famix Class)
I selected the [ | ]
there is self....
so I typed self inspect and I get an inspector on nil :(
what is self there?
Stef
We have
FAMIX.Entity extends Moose.Entity
FAMIXEntity is the abstract root class of the FAMIX meta-model entities.
Fields.
/annotationInstances: AnnotationInstance* → annotatedEntity
Proposed new version:
----------------------------------------------------------------------------------------------------------------
FAMIX.Entity extends Moose.Entity
FAMIXEntity is the abstract root class of the FAMIX meta-model entities. Subclasses will represent structural entities
of program: relations, types, functions...
Any FAMIXEntity can be attached properties (declared using <property:longName:description:>), navigation queries using (<navigation:>) and simple state (using propertyAt: and propertyAt:put:).
Such behavior is important for extensibility. It is inherited from Moose.Entity (See MooseEntity).
Fields.
/annotationInstances: AnnotationInstance* → annotatedEntity
-----------------------------------------------------------------------------------------------------------------
Question why FAMIXAnnotationInstance are in Java Package?
Answer because /annotationInstances comes only from Java.
Question: could we tag fields as coming from a specific extension?
annotatedEntity
<MSEProperty: #annotatedEntity type: #FAMIXEntity opposite: #annotationInstances>
^ annotatedEntity
may be this is an opportunity to use <package: 'Java'>
Now how could we get that
<MSEProperty: #annotatedEntity type: #FAMIXEntity opposite: #annotationInstances>
is associated to <package: 'Java'>?
On Sep 18, 2011, at 2:50 PM, Marianne Huchard wrote:
> Bonjour tous les deux,
>
> J'ai lu le document du méta-modèle, j'ai installé Moose maintenant si vous pouvez me donner une indication pour ouvrir le méta-modèle, ça m'aidera car j'ai travaillé sur papier seulement.
si tu ouvres un browser de code apres tu peux chercher FamixClass par exemple et sur le code class.
Si tu cliques sur le menu principal (fond d'ecran)
Moose
MooseMetaBrowser
tu obtiens un outil pour parcourir les metamodeles.
> Pour le rapport, il faudra que l'on rédige un texte descriptif général du méta-modèle qui en donne les orientations principales avant de se lancer dans le détail classe par classe. Je peux faire ça si j'ai un schéma.
Oui on doit faire cela.
> Voici ce qui m'a sauté aux yeux dans cette première lecture.
Marianne cela serait bien d'utiliser la mailing list moose car doru et simon la lise
>
> - les associations sont seulement binaires
>
> - je note qu'il y a un certain nombre d'attributs qui ne stocke pas "le modèle" lui-même mais plutôt des statistiques sur l'élément (ex nombre de lignes de code dans un namespace)
> Donc sur les paquetages, on pourrait ajouter d'autres métriques plus précises que le nombre de paquetages clients (ex. nombre de classes clientes, type de client - par quelle relation on est client) ?
> Cela va nous demander une petite analyse, à moins que ce ne soit assez facile ?
Il y a un package Cook et un autre chef (these hani) qui calcule plein de metriques sur les pacjage
> - Est-ce que si on veut modéliser des relations entre paquetages on pourra utiliser des instances d'"Association" ?
je ne sais pas mais a priori pourquoi pas.
>
> - en Java, est-ce supposé être exhaustif ?
par forcement car pour nos analyses il se peut que l'on en ait pas besoin.
> -- dans les types paramétrés, on ne voit pas les bornes (comme pour <A extends Comparable>)
> -- je n'ai pas vu les types interfaces, la relation implements
les interfaces sont gerees comme des classes abstraites
> Ensuite les questions qui se posent sont :
> - dériverons-nous de Famix-core notre modèle de package si on veut y ajouter des choses (je suppose que oui) et dans ce cas, comment cette dérivation se situe-t-elle par rapport au modèle Java par exemple ou Smalltalk (elle va rester parallèle ?).
en fait tu peux faire cela dans un package que l'on charge ou pas.
Normalement (mais on ne l'a jamais vriament utiliser) FAME permet la definition incremental d'elements (c'est pour cela qu'il y a un tag package)
car on pourrait groupe dans un package fame (au metamodel) les extensions que l'on veut faire.
Maintenant dans la pratique on code cela en Smalltalk et le mecanisme d'extension des packages Smalltalk est utilise.
> Y a-t-il dans Famix une relation "merge" entre packages semblable à celle du méta-modèle UML ?
> - qu'ajouterons-nous : j'en discute avec Roland puisque nous devons faire le délivrable
> "Model for modular abstractions in current languages"
je ne sais pas.
Notre objectif est
- ameliorer la documentation de famix dans moose
- creer un document de references (tech report) sur famix 3.0
apres on peut faire des plugins
Bon j'ai fait une passe sur mon budget et mardi andre revient et on va planifier une ou deux dates pour venir vous voir.
Stef
>
> A suivre !
> Marianne
>
>
>
>
>
On Sep 16, 2011, at 5:46 PM, mpescuma(a)libero.it wrote:
> Hi Stephane...
> I'm a developer that needs to extract some information from moose analysis (ex. properties and its values) ... exists a way to do this from a java or c++ program without launching the moose user interface ?
You can script moose by passing a script on the command line. You could also conect via a socket.
> My goal is this: starting from a java project, build with inFusion the .mse project... then without launching the moose user interfarce extract the moose analysis with specific library API (has the moose an api library ?) ... building around this a my program or user interface.
> Can I access to moose analisys using a specific library ? Exists this way ? If yes, how can do it ?
No for the moment the VM does not let us simply talk to objects inside it.
> If no, can moose suite produce a file (or something of equivalent) with his analysis of the project, the same that I can see with the user interface ?
sure there exporters in tab separated formats. Now writing a specific exporter should be easy and I would look at the one that export and filter
mse files. Andre (when you are back from holidays) can you give michele some pointers?
>
> thanks a lot,
> Michele.
Hi,
I'm making some progress here... but now I need another feature.
As I'm using glamour and magritte to present some data who is persistent, I need to being able to react to a #save call on a magritte presentation.
For instance... in my browser:
...
browser transmit
to: #detail;
from: #list;
andShow: [ :presenter |
presenter magritte
title: [ :anItem | anItem asString ];
act: [ :presentation :anItem | self removeItem: anItem ]
icon: LWUIIcons / #userTrash
entitled: 'Borrar' ].
...
how can I know if user pressed #save and there is a modified object there? (to update persistent repository)
working with plain magritte, I'd do:
...
anObject asMorph
onAnswer: [ :value | blah, blah ];
morph.
...
...so... is there a way in glamour to react to updated objects?
cheers,
Esteban
Hello,
I am running two different versions of VerveineJ and I have two different
problems:
1. When running the following command from the freshly downloaded verveineJ
sh verveinej.sh -Xmx 2000m -
/Users/ubhatti/Desktop/moosedata/Openbravo-3.0MP2.1/src/org/openbravo/
I get:
Exception in thread "main" java.lang.IllegalStateException: invalid
environment settings
at org.eclipse.jdt.core.dom.ASTParser.getClasspath(ASTParser.java:248)
at org.eclipse.jdt.core.dom.ASTParser.createASTs(ASTParser.java:970)
at fr.inria.verveine.extractor.java.VerveineJParser.parse(Unknown Source)
at fr.inria.verveine.extractor.java.VerveineJParser.main(Unknown Source)
2. When running this command on a copy of VJ downloaded in June and running
this command:
sh verveinej.sh -Xmx 4000m -
/Users/ubhatti/Desktop/moosedata/Openbravo-3.0MP2.1/src/
I get:
Exception in thread "main" java.lang.OutOfMemoryError: Java heap space
at sun.reflect.GeneratedMethodAccessor23.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at ch.akuhn.fame.internal.MethodAccess.write(MethodAccess.java:98)
at
ch.akuhn.fame.fm3.PropertyDescription.writeAll(PropertyDescription.java:334)
at ch.akuhn.fame.parser.Importer$Elem$Attr.maybeEnd(Importer.java:95)
at ch.akuhn.fame.parser.Importer$Elem$Attr.endAttribute(Importer.java:85)
at ch.akuhn.fame.parser.Importer$Elem.endAttribute(Importer.java:126)
at ch.akuhn.fame.parser.Importer.endAttribute(Importer.java:233)
at ch.akuhn.fame.parser.Parser.attributeNode(Parser.java:123)
at ch.akuhn.fame.parser.Parser.elementNode(Parser.java:166)
at ch.akuhn.fame.parser.Parser.accept(Parser.java:105)
at ch.akuhn.fame.parser.Importer.readFrom(Importer.java:269)
at ch.akuhn.fame.Repository.importMSE(Repository.java:195)
at ch.akuhn.fame.Repository.importMSEFile(Repository.java:200)
at fr.inria.verveine.core.VerveineParser.linkToExisting(Unknown Source)
at fr.inria.verveine.extractor.java.VerveineJParser.parse(Unknown Source)
at fr.inria.verveine.extractor.java.VerveineJParser.main(Unknown Source)
The second problem is about parameterizing the VM. I have tried various
parameters but its not working. I'm surely doing something wrong here but
cant figure it out.
thanx in advance,
Usman
Hi,
I'm again working with glamour.
I have this browser:
buildBrowser
| browser |
browser := GLMTabulator new
column: #list;
column: #detail;
yourself.
browser transmit
to: #list;
andShow: [ :presenter |
presenter list
title: [ self crudClass description label ];
act: [ self addItem ]
icon: LWUIIcons / #listAdd
entitled: 'Agregar';
selectionAct:[ :presentation :anItem | self removeItem: anItem ]
icon: LWUIIcons / #userTrash
entitled: 'Borrar';
updateOn: LWUIItemRemoved from: [ self announcer ];
display: [ self itemsSortedIfNecessary ] ].
browser transmit
to: #detail;
from: #list;
andShow: [ :presenter |
presenter magritte
title: [ :anItem | anItem asString ];
updateOn: LWUIItemRemoved from: [ self announcer ];
act: [ :presentation :anItem | self removeItem: anItem ]
icon: LWUIIcons / #userTrash
entitled: 'Borrar' ].
^browser
(don't take into account the spanish words :) )
the idea is this: I'm making a simple CRUD for some classes... and this is the problem:
1) when calling "removeItem", I update the list, and everything works fine... but I removed an element from the list, so... selection shouldn't be valid anymore, and the magritte presentation should be erased... and this does not happens.
2) I added the #updateOn:from: send to magritte presentation to see if something happens... and no, it never receives the update :(
so... I think there is a need to fix both problems: list presentations should trigger transmit update if selection no longer valid, and magritte presentation should react to updates.
Is that ok?
cheers,
Esteban