Runtime.exec() : Reboot in Android?

后端 未结 5 1132
慢半拍i
慢半拍i 2020-11-28 07:41

I\'m looking for a solution which can be used to reboot a rooted device. I jknow that rebooting a device is very poor design for the user, as stated here, and it\'s not real

5条回答
  •  醉话见心
    2020-11-28 08:25

    Finally after weeks of searching:

    Runtime.getRuntime().exec(new String[]{"/system/bin/su","-c","reboot now"});
    

提交回复
热议问题