title: How to programmatically force a full app restart? e.g. kill, then start
body: <p>I have an app that include both a complex service and activity UI. The app runs on multiple devices which communicate with each other over WIFI via the service.</p>
  
  <p>Since the app is a prototype/in-development, I want to add support for a "force restart" that will kill the app and re-launch it clean. There is a lot of shared UI stuff that has gotten gummed up depending on the use case, and it would be easier during testing (I have multiple devices) if I could just touch a button to restart the app completely.</p>
  
  <p>So, does anyone have any suggestions on how to:</p>
  
  <p>1) Force close/stop/kill your own app, from within your app.</p>
  
  <p>2) Set a timer/intent that tells the OS to launch your app before you close/stop/kill it.</p>
  
  <p>Any tips would be appreciated! Thank you.</p>