AW: $O - inherited class variables

Rudolf Bargholz rudolf at bargholz.ch
Thu Oct 21 07:34:53 UTC 2021


Hi Jean-Marc,

Do I understand you correctly that you want to change the subtype of an object variable in a class?

Set reference lObjVarRef to $root.$libs.MYLIB.$classes.MYCLASS.$methods.MYMETHOD.$lvardefs.oTest
Calculate lObjVarRef.$objsubtype as 'o7zip'

If you want to use notation to override a variable from inherited to overridden, that I have no idea how to do.

Regards

Rudolf

-----Ursprüngliche Nachricht-----
Von: omnisdev-en <omnisdev-en-bounces at lists.omnis-dev.com> Im Auftrag von jmv
Gesendet: Donnerstag, 21. Oktober 2021 08:06
An: OmnisDev List - English <omnisdev-en at lists.omnis-dev.com>
Betreff: Re: $O - inherited class variables

Hello Rudolf,

> Le 20 oct. 2021 à 16:34, Rudolf Bargholz <rudolf at bargholz.ch> a écrit :
> 
> Class variables cannot be inherited, but instance variables can. In your child class, you ought to see any inherited instance variables as blue variables. Right-mouse-click on the variable, and override the variable. You can not access the inherited variable and the overridden variable using the VariableName, or $cinst.VariableName. Note: this can feel a bit strange, as both variables are discreet and can have different values, even though the variable is in the superclass as well as in the subclass. 

Thank you for your answer.

I have a "tool" library that is open before others and contains "tools" referred to by variables "object".

It take a long times to search for every use of a variable.

And then manually override it with the definition of the proper library.

I have not found out how to do it programmatically, ie with code instead of the hand ;-)

best regards,

Jean-Marc
_____________________________________________________________
Manage your list subscriptions at http://lists.omnis-dev.com Start a new message -> mailto:omnisdev-en at lists.omnis-dev.com 


More information about the omnisdev-en mailing list