posted 17 years ago
Rajarsi-
I would like to add to what Wise Owen said; perhaps it would help you to see a situation.
An abstract class cannot be instantiated.
An abstract method MUST be overridden by subclasses.
This implies the following:
(I'm keeping it simple, and making the inheritance tree only 2 levels deep)
-- If you have an abstract class, it has to be subclassed (that is, extended) in order to be instantiated.
-- If your abstract class has abstract methods, then those methods have to be implemented in your subclass
-- If your abstract class has all of its methods defined, then it means that writing your subclass is really easy, because all those methods in the superclass are already implemented for you.
Can you see how this works?
A note about my simplification: you can subclass an abstract class, and make your subclass also abstract, and thus it would not have to define the abstract methods. But the first non-abstract class down the tree will have to do so; the methods in the first non-abstract class will be inherited in turn, by its subclasses.