If you know your classes will need to interact with other classes whose design may change, an interface is the way to go.
If you need to include some "base-level" or default behaviour (e.g. communications handling) in your class template then an abstract class allows you to do so.
Additionally, in C#, implementation of multiple interfaces is allowed, while multiple inheritance of base classes is not.
No comments:
Post a Comment