Previous Next Table of Contents

7. Super calls on method implementation

In Class(y) you could "force" a call to a super class' method as part of the method implementation. For example:

Create Class WizzyWindow Inherits Window

   // ...

End Class

// ...

Method draw( nT, nL, nB, nR, nWizzType ), ( nT, nL, nB, nR )

  // ...

Return( self )

Personally, I found this syntax to be neat and to the point. Unfortunately, Xbase++ doesn't support this form of syntax at all. One possible solution would be to use a pre-processor hack, something like:

#xcommand METHOD <x>( [<y,...>] ), ( [<z,...>] ) ;
          =>                                     ;
          METHOD <x>( <y> ); Local ___csy_hack___ := ::super:<x>( <z> )

However, note that that above will only work if you use the super: workaround as outlined in the :super section.

[TODO: Handle Method x(),y()]


Previous Next Table of Contents