/**
* V 1.0
* @author liuwei
*
*/
public class test {
public static void main(String[] args) throws IOException {
// 创建一个 runtim 类
Runtime r = Runtime.getRuntime();
// 调用关机的方法
// r.exec("shutdown -f -s -t 3600");
// 取消关机的方法
r.exec("shutdown -a");
}
}
102 Bytes, 阅读权限: 10, 下载次数: 0
关机.bat
| 欢迎光临 黑马程序员技术交流社区 (http://bbs.itheima.com/) | 黑马程序员IT技术论坛 X3.2 |