Is there away to for member which inherit a base class which has an interface to implement that interface.
Some interface
public interface ICanWork
{
void DoSomething();
}
some abstract class
public abstract Class MyBase : ICanWork
{
// I do not want to implement the ICanWork but instead want the derived class which inherit it
}
class which i inherit the base class
public class House : MyBase
{
// i want the compiler to know that it needs to implement ICanWork
}
This didn't work as i would expect.
Is the only way to achieve this by putting the Interface on the Class inherit the base class?
e.g.
public class House : MyBase, ICanWork
{
}
Any useful suggestions?