inheritance

Nick Harris nick.harris at exact.be
Thu Apr 16 06:16:12 EDT 2009


Franco
Firstly, objects:
You could override the $construct of the superclass with this:
Ie. Create a method in the object (in the subclass) called $construct.
Do $crecipient().$visible.$assign(kFalse)
Next Method Lines:
You can only inherit complete methods; that said you could create a
public method (ie. $MyMethodLine) in the subclass and call that from the
superclass with the following
Do $cinst().$MyMethodLine()
Once you get into and understand the OO paradigm you will wonder how you
ever managed beforehand, that said, it does kind of depend on you
getting that Eureka moment where it all suddenly fits.
Regards
Nick




-----Original Message-----
From: omnisdev-en-bounces at lists.omnis-dev.com
[mailto:omnisdev-en-bounces at lists.omnis-dev.com] On Behalf Of Franco
Maregotto
Sent: donderdag 16 april 2009 12:09
To: 'OmnisDev List - English'
Subject: O$: inheritance

I never used superclasses and subclasses until yesterday. Then, building
a
little library, I decided to try out this "strange" OO way.
The library deals with a rugby tournament with several teams,
distributed in
4 age categories.
After some hours of coding the windows instances (inherited from a
superclass) were done good but I have a wish:

It would be very nice to have the ability to override a single line of
code
of the superclass.
So in the subclass all lines of methods should be displayed blue (and
the
whole code being visible, not only a poor "Inherited from SuperClass")
Furthermore I wish to override an object in a window. If I have a single
exception (such a button) I have to remove it from the superclass and
add it
in every subclass, since it is not possible to change any property, like
forecolor, text etc..

But for sure I have not understood inheritance yet..
Maybe my wishes belong to a "not OO" vision of the inheritance
Where could I find some exhaustive documentation about?

Many TIA
Franco


_____________________________________________________________
Manage your list subscriptions at http://lists.omnis-dev.com



More information about the omnisdev-en mailing list