I did not see it because it is not in accessing as some of the other
methods.
I will group all the methods together in property
I tried to understand the difference between property:ifAbsent:
Basically this is the fact that ifNil: check to see if the property
could be computed because metadescribed.
I imagine that this is correct. Now when the property cannot be
computed this is ok to use ifNil too.
Now I have a question how do I make this guy working?
self mooseDescription
I still do not remember how to access meta stuff in fame.
propertyNamed: propertyName ifNil: aBlock
"Return the value of the property named propertyName, return nil if
the property does not exist"
^self privateState
at: propertyName asSymbol
ifAbsent:
[| property propertyOperator |
[propertyOperator := self mooseDescription computableAttributeNamed:
propertyName.
property := self mmGet: propertyOperator]
on: Error
do: [:ex | property := nil].
property ifNil: [aBlock value]]
On Sep 27, 2008, at 10:55 PM, Tudor Girba wrote:
Hi Stef,
There is such a method in AbstractEntity>>propertyNamed: propertyName
ifNil: aBlock
Doru
On Sep 27, 2008, at 10:46 PM, Stéphane Ducasse wrote:
Hi
I wanted to know why such method is not present in moose.
There is only
propertyAt:ifAbsentPut:
I will add it.
Stef
_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
--
www.tudorgirba.com
www.tudorgirba.com/blog
"Every now and then stop and ask yourself if the war you're fighting
is the right one."
_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch
https://www.iam.unibe.ch/mailman/listinfo/moose-dev