Quick Index
Overview


A video to go along with this page.

In this section will look at how to code a class.

Coding Phases


We'll break coding a class into two phases:


We want to start with phase 1, as the object structure will provide the foundation for coding the instance methods.

Coding Object Structure


Concepts


When coding the object structure, we focus on these three facets of the class:


Examples



Coding Public Instance Methods


Concepts


With the object structure in place, we're now ready for the fun part, which is coding the object behaviors (i.e., methods).

From the requirements we have a listing of required instance method headers and descriptions. These may be provided in the form of an ADT.

"NOTE WELL" -- unit tests should also be coded in parallel with the model (problem solution) code.

Examples




Navigation