Interfaces
- Since Java does not permit multiple inheritance with subclassing, (and therefore might have made it difficult for one class to integrate the functionality of several others) it compensates by providing formal interfaces.
- An interface consists of a name and a protocol (list of functions and their formal parameter types).
- A class may subclass at most one superclass but may implement any number of interfaces.
- A class that implements an interface must provide an implementation for each function appearing in the interface.
- Interfaces do not provide any code and are used to enforce (at compile time) calling conventions within software applications.
- Interfaces can be extended.