import statements : import « Class Definition « Java Tutorial






  1. 'import' statements must come after the package statement but before the class declaration.
  2. The import keyword can appear multiple times in a class.
import java.io.File;
import java.util.List;

public class Demo {

    //...
}








5.30.import
5.30.1.Importing Other Classes
5.30.2.import statements
5.30.3.import all classes
5.30.4.fully qualified name