This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
.System class contains a public static final PrintStream object called out which belongs to another seperate package java.io.
That's why the System class needs to import PrintStream. A class needs to import the classes that are used in its source code, but not the classes of which it merely uses objects. The compiler can figure out what class "out" belongs to by looking it up in the System class.
Joined: Dec 31, 2007
Thank you so much.
I was searching for the clue using javap utility.But it lists out only the methods and instance variables present in a class it won't display any import statements.I think I must use jad(Java Decompiler )to know the implementation of a class.