How to kill all running applications in android?

后端 未结 4 550
情深已故
情深已故 2020-11-30 01:24

I want to kill all running applications in android .so for this task , i implemented following code. But it is not working .App still remains in running.

Act         


        
4条回答
  •  野性不改
    2020-11-30 02:06

    According to doc enter link description here

    Note that, though this API allows us to request to kill any process based on its PID, the kernel will still impose standard restrictions on which PIDs you are actually able to kill. Typically this means only the process running the caller's packages/application and any additional processes created by that app

    I test it, and it only kill process hosted my App.

提交回复
热议问题