Possible Duplicate:
Why should the Java compiler not support inheritance of imports?
Is it possible for me to do the following:
Say I have a class A which extends class B. B has imported class C which has it’s own methods that B uses. Can A use those same methods from C without importing C directly, since A extends B?
No.
But if you had said:
Say I have a class A which extends class B. B has
importedextended class C which has it’s own methods that B uses. Can A use those same methods from C without importing C directly, since A extends B.Then A could use C’s
protectedandpublicmethods (and friendly methods if its in the same package) without importing C.