On 18 Sep 2011, at 22:14, Stéphane Ducasse wrote:
Ok I will change the comment and the trait I will not do it for now. I want to focus on comments for now.
Sure. I was just thinking out loud :)
Doru
Stef
On Sep 18, 2011, at 9:12 PM, Tudor Girba wrote:
Sounds Ok. Actually, we now have an issue opened that says that we should merge MooseElement and MooseEntity because there is no point in having them separated anymore.
It would probably be better to have MooseElement as a Trait.
Doru
On 18 Sep 2011, at 19:18, Stéphane Ducasse wrote:
We have
MooseElement defines the minimal interface of an entity
Proposition: v2
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. It is generated automatically during the creation of the MooseEntity.
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.
No, it returns the name of the entity, or the symbol #noname.
so what do we write
MooseElement>>mooseName "Returns an unique identifier of this entity. This method is mandatory, and must return a Symbol or Integer that unqiuely identifies this entity within its model (but not within the entire Moose enivronment, see MooseElement>>mooseID). The return value must not be nil, and must never change. The implementation should be fast, as this key may be used extensivley by the MooseModel or similar facilities."
^self mooseID asString
Stef _______________________________________________ Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/mailman/listinfo/moose-dev
-- www.tudorgirba.com
"No matter how many recipes we know, we still value a chef."
Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/mailman/listinfo/moose-dev
-- www.tudorgirba.com
"Live like you mean it."