On Wed, Apr 3, 2013 at 7:36 PM, Nicolas Anquetil Nicolas.Anquetil@inria.frwrote:
then another question:
is there a logic behind the decision to use privateState or instance variables?
Instance variables are used for properties of the "basic" Famix meta-model. privateState are used for properties that are related to meta-model extensions such as Famix-Java, Famix-Smalltalk, Famix-Extensions, etc. Also, with privateState you can easily integrate your meta-model extension without the need to change the original meta-model (since you don't create instance variables). For example, in FAMIXMethod we have just 2 instance variables: kind and parentType. All the other properties, which are related to meta-model extensions, use privateState.
is it to save memory (as I understood from the mooseBook: "MinimalState")
But if so, is it really needed for something like a boolean (hasClassScope)?
#hasClassScope and #timeStamp for example are properties related to the Smalltalk meta-model. That's why it is better to use privateState.
nicolas
On 04/03/2013 05:55 PM, Tudor Girba wrote:
No, it is not.
privateState is not a meta-model property. It is only an implementation issue to offer state extensions in Pharo.
Cheers, Doru
On Apr 3, 2013, at 5:43 PM, Anne Etien anne.etien@univ-lille1.fr wrote:
Hi,
Shouldn't the hasClassScope property of FAMIXMethod be declared as <derived>? It is computed from privateState just as isConstructor or declaredExceptions which are derived.
Same question for timeStamp.
Thanks in advance.
Anne ______________________________**_________________ Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/**mailman/listinfo/moose-devhttps://www.iam.unibe.ch/mailman/listinfo/moose-dev
-- www.tudorgirba.com
"Presenting is storytelling."
______________________________**_________________ Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/**mailman/listinfo/moose-devhttps://www.iam.unibe.ch/mailman/listinfo/moose-dev
-- Nicolas Anquetil -- RMod research team (Inria)
______________________________**_________________ Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/**mailman/listinfo/moose-devhttps://www.iam.unibe.ch/mailman/listinfo/moose-dev