[android-developers] Re: Restarting Application Service

2010-12-28 Thread Prasath
i think i can use START_STICKY in case of the below scenario. This mode makes sense for things that will be explicitly started and stopped to run for arbitrary periods of time, such as a service performing background music playback since i'm hosting the widget from the device startup. i expect

Re: [android-developers] Re: Restarting Application Service

2010-12-28 Thread Dianne Hackborn
As the documentation says, setForeground has been replaced with startForeground. On Tue, Dec 28, 2010 at 7:14 PM, Prasath prasath.balakrish...@gmail.comwrote: i think i can use START_STICKY in case of the below scenario. This mode makes sense for things that will be explicitly started and

[android-developers] Re: Restarting a service.

2009-04-30 Thread Todd Sjolander
As I understand it, if your Service (or Activity, for that matter), dies due to the system reclaiming resources or a crash, the OS will restart it for you automatically. That means if you were to configure it to start upon boot (using android.permission.RECEIVE_BOOT_COMPLETED and implementing a