related to abstract base classes.
Let's poke some holes in it.
We're not talking about inheritance, nor do we really need to.
Why?
Because you don't give much thought to discussing inheritance when
supporting partial classes -- I know, you're right, not much is needed.
Ok, but my point is, let's be consistent.
I suggest:
NT should not give much background on inheritance when discussing
abstract base classes. Understandably, abstract base classes are a
much better example of inheritance. But my point is, so what if they're
'not documented' -- just give a couple of links to 3rd-party educational
websites and be done with it. Support folks do this often enough
already -- so be consistent -- just follow the same policy for abstract
base classes. If someone has a question about inheritance, point
them towards other educational resources on the web.
I mean, come on ...
This 'inheritance is not documented' is not much of a blocker, and kind of
a dumb reason. That is, the entire C# language is 'not documented' by
NinjaTrader, but that doesn't stop NinjaTrader from using Dispatchers,
or virtual methods, or delegates, or LINQ, or a whole host of other
relatively advanced features which are a fundamental part of the C#
language -- and therefore should not require 'documentation' from the
Support staff, or anybody else.
This generated wrapper code is for indicators only, and has nothing to
do with Strategies, or AddOns. Ok, we can agree on that.
Nevertheless, this issue is moot.
Support folks have already made the suggestion to move any partial
classes to the AddOns folder -- precisely to avoid issues related to
the generated code which is only ever added for Indicators.
So, this same workaround can be promoted by Support when
someone asks about abstract base classes.
Problem solved.
How do you know this?
Do you have an example?
I kinda doubt this is even possible.
Using an abstract base class does not change how objects
are instantiated. C# itself would be broken if Strategy objects
were not properly able to handle inheritance.
Just because my Strategy inherits from one or more abstract
base classes, as long as the lowest abstract base class is
inheriting from Strategy, what is the issue? The inheritance
hierarchy is always properly maintained, otherwise the C#
language itself is broken.
NT's reasoning on this is pure crap, er, I mean, just another
attempt at obfuscation. A red herring.
Please provide an example of the inheritance problems you
encountered during strategy optimizations.
Understood, but partial classes are also a broader C# concept,
and the partial class concept is 'supported'. Barely.
I know Support folks are not there for C# education -- but plenty
of times Support will gently sidestep the issue of education by
providing links to 3rd party C# language education resources.
Ok, so, do that for inheritance. Do that for abstract base classes.
Support is not lazy, you guys graciously help others learn C# by
providing such links already.
My point is: You've already established precedent for providing
educational links, so you can't now reply upon the lack of an
in-house educational resource and call it a barrier for support
of the C# language feature called abstract base classes.
So, what's the problem?
Find some good 3rd-party links, have them at the ready, just
like you do for other aspects of the C# language.
My point is: there is no problem.
This is a another red herring.
Without example code, I think this is baloney.
Until proven otherwise, it is baloney.
I'll say it again:
The C# language supports abstract bases classes just fine.
The NinjaScript framework supports abstract bases classes just fine.
An abstract base class 'extends' the inheritance hierarchy, which is
always maintained correctly, even during Strategy optimizations --
otherwise, the C# language itself is broken. And I do not believe
Support's wild accusations that inheritance in C# is broken.
My final summary is this:
In the world of providing support examples and advice, there is
absolutely no reason why abstract base classes should not enjoy
equal footing with partial classes.
-=o=-
Just my 2˘.
Comment