Hi,
On 30 Oct 2011, at 23:01, Stéphane Ducasse wrote:
The comment got lost when we merged MooseElement with MooseEntity (given that MooseEntity was the only subclass).
Well, the MooseElement>>mooseName original implementation was not used anymore, as mooseName got overridden in MooseEntity (which used to be a subclass of MooseElement). Furthermore, mooseName is no longer a unique identifier, so the comment was partly obsolete.
So, now I just kept:
"The return value must not be nil, and must never change. The implementation should be fast, as this key may be used extensively by MooseGroup or similar facilities.
Do not override this method. Instead, use mooseNameOn: to customize the result."
where? Because I added it back in my image.
I just committed :).
Doru
Stef
Cheers, Doru
On 30 Oct 2011, at 20:44, Stéphane Ducasse wrote:
Hi guys
MooseElement>>mooseName "Returns an unique identifier of this entity. This method is mandatory, and must return a Symbol or Integer that uniquely 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 "asSymbol -- check if this really works with Integers as well, else change sender!"
was like that and now MooseEntity>>mooseName
mooseName | stream | ^ self privateState propertyAt: #mooseName ifAbsentPut: [ stream := (String new: 64) writeStream. self mooseNameOn: stream. ^ stream contents asSymbol ]
so why the comment got lost?
Stef _______________________________________________ Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/mailman/listinfo/moose-dev
-- www.tudorgirba.com
"If you interrupt the barber while he is cutting your hair, you will end up with a messy haircut."
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
"Speaking louder won't make the point worthier."