Let's look at some examples from the standard Java API:
The interface Comparable
is implemented by many classes, like File
and Integer
, which are unrelated to each other. There's a whole list of classes which implement Comparable
in the link above. That's fine, because Comparable
defines only a single method (compareTo
) which every class implements on its own way, without some shared code which could be beneficial to every Comparable
class.
On the other hand, two classes extending a single abstract class like Format
are usually closely related, like DateFormat
and NumberFormat
. The abstract class allows for the definition of some convenience/utility methods which are useful for every subclass.