next up previous contents
Next: getState(), setState(), and isProperty() Up: Class Interface Previous: Virtual destructor   Contents

Order by access level

Order your class declaration top-down in the header file by access level: public, protected, and then private. When Waldo decides that he wants to use your class he will browse through your class declaration looking for methods that he can call on the object. By placing private members first Waldo would be immediately confronted with members he cannot use. Therefore, place publicly accessible member functions at the beginning of the header file. Do not have multiple sections of each access level. It is confusing to have to switch back and forth between access levels when trying to learn what a class can do.



Falko Kuester 2001-08-24