Wed 4 May 2005
Private Methods Useless?
Posted by dkaz under Java
Is there any good reason to write “private” methods in Java?
I’m not so sure.
Virtually every class I write these days ends up having a mix of
“public” and “package private” methods.
In a way, “private” is my marker interface for “not tested in isolation”.
Googling the topic this evening took me to an interesting c2 wiki page:
http://c2.com/cgi/wiki?MethodsShouldBePublic
