如何能够通过代码来重启Android手机?

String cmd = "su -c reboot";//让手机从启

     try {

         Runtime.getRuntime().exec(cmd);

    } catch (IOException e) {

    // TODO Auto-generated catch block

     new AlertDialog.Builder(this).setTitle("Error").setMessage(

        e.getMessage()).setPositiveButton("OK", null).show();

 }

原文地址:https://www.cnblogs.com/leehongee/p/3323901.html