AP® Computer Science A glossary

Anatomy of a class

Also called: class structure, parts of a class

Course: AP® Computer Science A Shows up in: Unit 3: Class Creation

The parts of a Java class: the class header, instance variables, constructors and methods, each with its access modifier.

Appears in the course and exam description (CED): 3.3.A.23.3.A.33.3.A.53.3.A.6

In this course a class is declared public class Name. Inside come the private instance variables, then public constructors, then methods: public for behaviors, private for helpers used only inside the class.

Learn it properly, with a checkpoint 3.3 Anatomy of a Class

Related terms

Was this page helpful?

No names are ever shown, and every public comment is checked by us first. Please do not include personal details. To get a reply, email [email protected].

↑ Top

Enlarged view of the selected figure