Trail: Learning the Java Language
Lesson: Interfaces and Inheritance
Section: Interfaces
Summary of Interfaces
Home Page > Learning the Java Language > Interfaces and Inheritance

Summary of Interfaces

An interface declaration can contain method signatures, default methods, static methods and constant definitions. The only methods that have implementations are default and static methods.

A class that implements an interface must implement all the methods declared in the interface.

An interface name can be used anywhere a type can be used.

Problems with the examples? Try Compiling and Running the Examples: FAQs.
Complaints? Compliments? Suggestions? Give us your feedback.

Previous page: Default Methods
Next page: Questions and Exercises: Interfaces