Base class with abstract subclasses in C# ?
Posted
by Nick Brooks
on Stack Overflow
See other posts from Stack Overflow
or by Nick Brooks
Published on 2010-04-11T20:15:17Z
Indexed on
2010/04/11
20:33 UTC
Read the original article
Hit count: 265
public abstract class Request
{
public class Parameters
{
//Threre are no members here
//But there should be in inherited classes
}
public Request()
{
parameters = new Parameters();
}
public Parameters parameters;
}
Two questions:
How do I make it so I can add stuff to the constructor but the original constructor will still be executed?
How do I make it so the subclasses can add members to the Parameters class?
© Stack Overflow or respective owner