You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Hi all,
I am pretty new to MQL4 and have a question about polymorphism in MQL4 which think will be most clear if I show some C# code of what I am trying to achieve:
So, from class D, i want to be able to call the function X on member t. I know MQL4 does not have the concept of generics, but does anybody have any idea of how I can achieve something similar to the code above, but then in MQL4? The only thing I could think of is the code below, but that includes a downcast from T to B (and needs an extra private function Y), which does not seem right at all...
Who can help me with this one?
Thanks!!