[android-developers] Re: Running Application as Service

2009-09-10 Thread javame_android

Hi,

I am currently just registering Broadcast Receiver for reading
incoming messages. And this also works in Background which is what I
required. Now is that Broadcast Receiver unregistered by Android
Application Manager automatically or will it be able to process every
incoming message.

I just want to read incoming message process it and if it contains a
specific content then send the current location of that  to the number
from which the message arrived.

Will just extending Broadcast Receiver do the work or will I need to
implement it as Service so that it runs forever. I have checked the
Broadcast Receiver it works for now.

One more question when will this Broadcast Receiver be called. Suppose
the mobile is switched on then will this receiver be registered
automatically.



Regards
Sunil
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Running Application as Service

2009-09-10 Thread javame_android

Hi,

I want to continuously listen for incoming messages in background. So
what would be the best way of doing it? Shall I make that application
as Service or just registering it as BroadCast Receiver would do. If I
register the listener then will it keep on running continuously. This
receiver should be able to receive all the incoming messages.

Hope to get the reply soon.


Regards
Sunil
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Running Application as Service

2009-09-09 Thread Mark Murphy

javame_android wrote:
> I want the application to run in background. This application should
> run continuously and should never get killed.

Strictly speaking, that is not possible.

> Will running application as Service solve this issue?

Not really. Services can be killed by Android (e.g., low memory
conditions) or by the user (e.g., Force Close button in Manage
Applications).

You can roll your own firmware and create daemons and such that are not
subject to being killed.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://twitter.com/commonsguy

Need help for your Android OSS project? http://wiki.andmob.org/hado

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---