Private vs. Protected Members/Properties

Filed under Software, Development, Theory, OOP by Rabbitt on Friday March 24, 2006

So it’s been a while since I last posted anything and I just found this interesting page with an algorithm for choosing the correct scope for a class member/property - figured I’d share it for anyone interested:

Pretty much every object oriented programming language let’s you set the visibility of object members. Usually it defaults to public. That means everybody can access that member. Of course often you don’t want to [allow] other objects to access certain parts of your object. This is where private or protected come in to play.

— see: Michiel “El Muerte” Hendriks for more…

Popularity: 100%

Strange way to start off…

Filed under People by Rabbitt on Monday July 25, 2005

14 queries. 0.038 seconds.
Powered by Wordpress
theme by evil.bert