Win a copy of Java by Comparison (eBook) this week in the Java in General forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

import & classpath  RSS feed

 
Ranch Hand
Posts: 42
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi ,
If in code import is given like import com.xyz.*;
then there is no need to mention this in classpath for both java and javac .

Is my assumption correct ???

Regards,
Sharath.
 
Ranch Hand
Posts: 518
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
All classes need to be somewhere in the classpath.

How the import is specified is irrelevant. In fact javac converts import wildcards into specific import statements of the classes used.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!