Hi,
Imagine I have a package Super with a class Super and a package Sub with a class Sub that inherits from Super.
If I create a moose model of the package Super, I get the class Sub as a stub. I find that very surprising: why are all subclasses of the system included in the model. The semantics of the inheritance relation is one-way: a class knows its super class, not the opposite.
Can somebody explain why subclasses are included in the analyses?
2014-10-02 11:39 GMT+02:00 Damien Cassou damien.cassou@gmail.com:
Hi,
Imagine I have a package Super with a class Super and a package Sub with a class Sub that inherits from Super.
If I create a moose model of the package Super, I get the class Sub as a stub. I find that very surprising: why are all subclasses of the system included in the model. The semantics of the inheritance relation is one-way: a class knows its super class, not the opposite.
Can somebody explain why subclasses are included in the analyses?
I don't know much about the moose model and I consider inheritance as an one-way relationship too, but otherwise, a Smalltalk class *knows* its subclasses.
-- Damien Cassou http://damiencassou.seasidehosting.st
"Success is the ability to go from one failure to another without losing enthusiasm." Winston Churchill _______________________________________________ Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/mailman/listinfo/moose-dev
I understand that the rational behind this, is to populate stubs with the maximum amount of information. Is this a problem however?
Cheers, Alexandre
On Oct 2, 2014, at 6:39 AM, Damien Cassou damien.cassou@gmail.com wrote:
Hi,
Imagine I have a package Super with a class Super and a package Sub with a class Sub that inherits from Super.
If I create a moose model of the package Super, I get the class Sub as a stub. I find that very surprising: why are all subclasses of the system included in the model. The semantics of the inheritance relation is one-way: a class knows its super class, not the opposite.
Can somebody explain why subclasses are included in the analyses?
-- Damien Cassou http://damiencassou.seasidehosting.st
"Success is the ability to go from one failure to another without losing enthusiasm." Winston Churchill _______________________________________________ Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/mailman/listinfo/moose-dev
It may be a problem since when you want to analyse a package, you may not want to pull with him all the subclasses that are in other package. Moreover, we don’t have the same behavior in all languages (for example, in java and ST).
It is possible to choose not pulling the method extension, it could be good to have the same opportunity while creating an mse from ST code not dragging all the subclasses when they are stub, no ?
Cheers, Anne Le 2 oct. 2014 à 17:07, Alexandre Bergel alexandre.bergel@me.com a écrit :
I understand that the rational behind this, is to populate stubs with the maximum amount of information. Is this a problem however?
Cheers, Alexandre
On Oct 2, 2014, at 6:39 AM, Damien Cassou damien.cassou@gmail.com wrote:
Hi,
Imagine I have a package Super with a class Super and a package Sub with a class Sub that inherits from Super.
If I create a moose model of the package Super, I get the class Sub as a stub. I find that very surprising: why are all subclasses of the system included in the model. The semantics of the inheritance relation is one-way: a class knows its super class, not the opposite.
Can somebody explain why subclasses are included in the analyses?
-- Damien Cassou http://damiencassou.seasidehosting.st
"Success is the ability to go from one failure to another without losing enthusiasm." Winston Churchill _______________________________________________ Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/mailman/listinfo/moose-dev
-- _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;: Alexandre Bergel http://www.bergel.eu ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/mailman/listinfo/moose-dev
We could customise the smalltalk importer. Damien have a look at the Importer may be we can add a setting to control that.
On 2/10/14 11:39, Damien Cassou wrote:
Hi,
Imagine I have a package Super with a class Super and a package Sub with a class Sub that inherits from Super.
If I create a moose model of the package Super, I get the class Sub as a stub. I find that very surprising: why are all subclasses of the system included in the model. The semantics of the inheritance relation is one-way: a class knows its super class, not the opposite.
Can somebody explain why subclasses are included in the analyses?
We customized the smalltalk importer in order to support the not blind importing of subclasses. We also added tests.
Anne (and Stéphane) Le 4 oct. 2014 à 07:54, stepharo stepharo@free.fr a écrit :
We could customise the smalltalk importer. Damien have a look at the Importer may be we can add a setting to control that.
On 2/10/14 11:39, Damien Cassou wrote:
Hi,
Imagine I have a package Super with a class Super and a package Sub with a class Sub that inherits from Super.
If I create a moose model of the package Super, I get the class Sub as a stub. I find that very surprising: why are all subclasses of the system included in the model. The semantics of the inheritance relation is one-way: a class knows its super class, not the opposite.
Can somebody explain why subclasses are included in the analyses?
Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/mailman/listinfo/moose-dev