What is the difference between abstract class and an interface?

An interface is a way of ensuring a class contains all required methods and properties, can be used to idenfify a class without using the class name for dependancy injection, but the interface itself contains no logic.
An abstract class is a class that contains methods and properties that can be overriden, this links to the open/closed principle in SOLID.
References
Advertisements