[android-developers] Remote Service - Reconnecting
Hi,
I have implemented a RemoteService which will increment a countere
( just for testing purposes ). Therefore I have a Task class which
implements Runnable and the method run() where a infinite while loop
increments the variable.
From the client side, I start the RemoteService with startService and
then i bind to the service. When I close the activity, the service is
still running.
Now i want to rebind to the service.
How do I know if the service has already been started (therefore i
would only need to bind to the service again) or not (then I would
need to call startService() first and then bind to the service)?
What would happen, if I call startService() if the service is already
running? Does the OS start a second service, or will it affect the
service which is already running?
I am a little confused an can't find the answer in the developer
resources.
Thanks for your help in advance,
regards, Markus
--
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+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home