What is an abstract class, and when should it be used?

Abstract classes are classes that contain one or more abstract methods. An abstract method is a method that is declared, but contains no implementation. Abstract classes may not be instantiated, and require subclasses to provide implementations for the abstract methods. Let’s look at an example of an abstract class, and an abstract method. Suppose we were modeling the behavior of animals, by creating a class … Continue reading What is an abstract class, and when should it be used?