How to restart computer using simple java program
i have a code for shut down how is restart and hibernate can be done
code is
import java.util.*;
import java.io.*;
public class BadExecJavac
{
public static void main(String args[])
{
try
{
Runtime rt = Runtime.getRuntime();
Process proc = rt.exec("shutdown -t 10");
}catch (Exception e)
{
System.out.print(e);
}
}
}