On Tue, Feb 25, 2014 at 8:33 PM, Gustavo Santos <gugajansen@gmail.com> wrote:
Hi everybody,

I'm currently trying to programatically copy a Moose model
Which model, Java or Smalltalk? 

What happens is that only the message isInterface returns nil, when the original Moose model has this information. All the other "is*" messages return something or false. I have no problem copying other information from the model whatsoever.
In a Smalltalk model #isInterface returns false, which is ok.
I don't know how you obtain nil because the default is false (see FAMIXClass>>isInterface). OK, the instance variable is nil, so maybe you are in a subclass of FAMIXClass accessing this instance variable. In this case you should call the *getter method* #isInterface to get false instead of nil.

Looking at the code, this variable is directly set on FAMIXClass>>#isInterface: and the other ones use the FAMIXNamedEntity>>modifierSet:for: message (lazy attribution I guess)
No, this is not lazy attribution; modifiers is only a Set (see the method FAMIXNamedEntity>>initialize) which is used in order to avoid create instance variables.
isInterface is an instance variable, so it does not need to use the modifiers.

So, why this specific information is not set? Can we change this?
I don't think it is needed, or maybe I lost something in the lines :)

Cheers,
--
Gustavo Santos

_______________________________________________
Moose-dev mailing list
Moose-dev@iam.unibe.ch
https://www.iam.unibe.ch/mailman/listinfo/moose-dev




--
Andre Ho