I am writing a series of math class, each of which inherits from an abstract class. I want my abstract class to have a getter and setter called Parameters.
public abstract dynamic Parameters {get; set;}
Then, in each individual math class, I want to implement parameters with a specific type:
If a class needs a period, I would do it like this:
public override IPeriod Parameters {get; set;}
This does not compile. Obviously, I could change the return type to dynamic , and this will work, but then I will lose intellisense. Is there a standard way to do this without losing intellisense?
Each of the classes will have {get; set;} but they will be of a different type. Is it better to just exclude parameters from an abstract class?
source share