Lecture 4 Objectives
At the end of today's class you should
KNOW:
- that an abstract class is a mechanism provided by Java to facilitate
sharing of code and data
- that abstract classes can't be instantiated
- that a class can extend at most one other class (abstract or concrete)
- that a class can implement any number of interfaces
BE ABLE TO:
- design a class hierarchy for classes that have multiple properties
Sample Exam Question:
Suppose we want to create a category of animals that are four-legged (i.e.
Dillos and Tigers).
Suggest a way to modify the animal hierarchy we developed in class today
to accomodate this addition.