A browser with JavaScript enabled is required for this page to operate properly.
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 defines a protocol of communication between two objects.

An interface declaration contains signatures, but no implementations, for a set of methods, and might also contain constant definitions.

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: Rewriting Interfaces
Next page: Questions and Exercises: Interfaces