Java Reference
In-Depth Information
methods that must be implemented by any class that implements the
extended interface.
A class's supertypes are the class it extends and the interfaces it imple-
ments, including all the supertypes of those classes and interfaces. So
an object is not only an instance of its particular class but also of any of
its supertypes, including interfaces. An object can be used polymorph-
ically with both its superclass and any superinterfaces, including any of
their supertypes.
A class's subtypes are the classes that extend it, including all of their
subtypes. An interface's subtypes are the interfaces that extend it, and
the classes that implement it, including all of their subtypes.
Exercise 1.15 : Write an interface that extends Lookup to declare add and
remove methods. Implement the extended interface in a new class.
 
Search WWH ::




Custom Search