/**
Visibility of Accessors
*/
Always strive to make them protected, so that subclasses can access the fields. Only when an 'outside class' needs to access a field should you make the corresponding getter or setter public. Note that it is common that the getter member function be public and the setter protected.
Tuesday, November 11, 2008
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment