The Artima Developer Community
Sponsored Link

Legacy Java Answers Forum
January 2002



This page contains an archived post to the Java Answers Forum made prior to February 25, 2002. If you wish to participate in discussions, please visit the new Artima Forums.



Posted by Matt Gerrans on January 25, 2002 at 3:03 PM

> Thanks for the help Anil. I somewhat understand what you're doing, but not fully. I can just try some stuff and hope I get it correctly. Thanks again.
> Hiran

Here are a couple more hints on the subject:

  1. Put classes which want to be intimate with one another in the same package.
  2. Of course, you also group things in a package logically.
  3. In particular, if your class B is extending class A, from another package, then those things which B needs to access from its base (A), should be protected (or public, of course, if everyone should have access).


Sponsored Links

Copyright © 1996-2009 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use - Advertise with Us