日期:2014-05-20 浏览次数:20655 次
Process process = Runtime.getRuntime().exec ("cmd.exe"); BufferedReader bufferedReader = new BufferedReader( new InputStreamReader(process.getInputStream())); String line; while ((line = bufferedReader.readLine ()) != null) { System.out.println(line); System.out.flush(); }