Calling base class
(Adding message template to the top of the page)
(Updated Edited template to July 12, 2025.)
 
(One intermediate revision by one other user not shown)
Line 1: Line 1:
{{message|Write the content here to display this box}}
<message>Write the content here to display this box</message>
EAL (Extended Action Language) is fantastic as it allows you to create a complete system without bringing out Visual Studio or C# at all (nothing is wrong with C# – but it is amazing to be able to execute the model alone). It had a limitation: when overriding methods, there was no way to call the base class implementation of the method.
EAL (Extended Action Language) is fantastic as it allows you to create a complete system without bringing out Visual Studio or C# at all (nothing is wrong with C# – but it is amazing to be able to execute the model alone). It had a limitation: when overriding methods, there was no way to call the base class implementation of the method.


Line 24: Line 24:
…as in the RootClass added “RA” and the Person added “PA.”
…as in the RootClass added “RA” and the Person added “PA.”
[[Category:EAL]]
[[Category:EAL]]
{{Edited|July|12|2024}}
{{Edited|July|12|2025}}

Latest revision as of 05:46, 20 January 2025

This page was created by Alexandra on 2018-10-21. Last edited by Edgar on 2025-01-20.

EAL (Extended Action Language) is fantastic as it allows you to create a complete system without bringing out Visual Studio or C# at all (nothing is wrong with C# – but it is amazing to be able to execute the model alone). It had a limitation: when overriding methods, there was no way to call the base class implementation of the method.

Now that is fixed by introducing the EAL operation “base” – it works just as in C#:

Base class - 1.png

Given the OnCreate method (that is called when an object is created).

The RootClass.OnCreate

Base class - 2.png

And the Person.OnCreate

Base class - 3.png

Note the self.base.OnCreate call that calls the superclass implementation of OnCreate (just as in C#)

And when creating a new Person, I got this output:

Base class - 4.png

…as in the RootClass added “RA” and the Person added “PA.”