So, I have this project structure:
AB package
- class
SuperClass (this class is marked as private)
ABC package
- class
SubClass (inherited from the superclass)
I would rather not make SuperClass public ... It's really just a utility class for this particular project (AB).
It seems to me that SubClass should be able to see SuperClass , because the ABC package is a subpackage of AB .. but it is not.
What would be the best way to solve this problem? I donβt think it makes sense to move everything in ABC to AB or move AB to ABC .. mainly because there will probably be an ABD that inherits from things in AB, as well ...
I'm a little new to Java, so be nice: D (I'm a C ++ and .NET guy)
java inheritance packages organization
Polaris878
source share