下面是它的api文档:
java.lang 
Class System
java.lang.Object
  |
  +--java.lang.System
--------------------------------------------------------------------------------public final class System
extends Object
The System class contains several useful class fields and methods. It cannot be instantiated. Among the facilities provided by the System class are standard input, standard output, and error output streams; access to externally defined "properties"; a means of loading files and libraries; and a utility method for quickly copying a portion of an array. Since:
JDK1.0 --------------------------------------------------------------------------------Field Summary 
static PrintStream err 
          The "standard" error output stream. 
static InputStream in 
          The "standard" input stream. 
static PrintStream out 
          The "standard" output stream. 
  Method Summary 
static void arraycopy(Object src, int srcPos, Object dest, int destPos, int length) 
          Copies an array from the specified source array, beginning at the specified position, to the specified position of the destination array. 
static long currentTimeMillis() 
          Returns the current time in milliseconds. 
static void exit(int status) 
          Terminates the currently running Java Virtual Machine. 
static void gc() 
          Runs the garbage collector. 
static String getenv(String name) 
          Deprecated. The preferred way to extract system-dependent information is the system properties of the java.lang.System.getProperty methods and the corresponding getTypeName methods of the Boolean, Integer, and Long primitive types. For example: 
     String classPath = System.getProperty("java.class.path",".");
 
     if (Boolean.getBoolean("myapp.exper.mode"))
         enableExpertCommands();
 
 
static Properties getProperties() 
          Determines the current system properties. 
static String getProperty(String key) 
          Gets the system property indicated by the specified key. 
static String getProperty(String key, String def) 
          Gets the system property indicated by the specified key. 
static SecurityManager getSecurityManager() 
          Gets the system security interface. 
static int identityHashCode(Object x) 
          Returns the same hash code for the given object as would be returned by the default method hashCode(), whether or not the given object's class overrides hashCode(). 
static void load(String filename) 
          Loads a code file with the specified filename from the local file system as a dynamic library. 
static void loadLibrary(String libname) 
          Loads the system library specified by the libname argument. 
static String mapLibraryName(String libname) 
          Maps a library name into a platform-specific string representing a native library. 
static void runFinalization() 
          Runs the finalization methods of any objects pending finalization. 
static void runFinalizersOnExit(boolean value) 
          Deprecated. This method is inherently unsafe. It may result in finalizers being called on live objects while other threads are concurrently manipulating those objects, resulting in erratic behavior or deadlock. 
static void setErr(PrintStream err) 
          Reassigns the "standard" error output stream. 
static void setIn(InputStream in) 
          Reassigns the "standard" input stream. 
static void setOut(PrintStream out) 
          Reassigns the "standard" output stream. 
static void setProperties(Properties props) 
          Sets the system properties to the Properties argument. 
static String setProperty(String key, String value) 
          Sets the system property indicated by the specified key. 
static void setSecurityManager(SecurityManager s) 
          Sets the System security. 

解决方案 »

  1.   

    包含?是不是指导入?java.lang包是不用显式导入的,java程序会默认导入,所以可以直接用System类。
      

  2.   

    使用System类的时候不需要显示的导入什么包文件!
      

  3.   

    System类位于package java.lang下面, 凡是此package下面的类我们可以直接引用无需先import进来, 因为JVM缺省就load了这下面的所有class。
    System包含了一些我们常用的方法与成员变量。 System不能被实例化, 所有的方法都可以直接引用。