3. Declarations


3.1 Class Declarations

A class declaration introduces a new reference type. For the purpose of this book, we will use the following simplified syntax of a class declaration:

class_modifiers class class_name                                      extends_clause                                      implements_clause // Class header{ // Class body          field_declarations          method_declarations          constructor_declarations}

In the class header, the name of the class is preceded by the keyword ...

Get A Programmer’s Guide to Java® SE 8 Oracle Certified Associate (OCA) now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.