On Jul 6, 2:20 pm, Mark Murphy <mmur...@commonsware.com> wrote:
> If your service is started via bindService(), it will be stopped
> sometime after the last client unbinds.
>
> If your service is started via startService(), it will run into somebody
> tells it to stop (stopService(), stopSelf(), Android terminating the
> process, gravity and a concrete floor negatively impacting the device).
>
> If you wish to use AIDL, but still want the service to run even after
> unbinding, use both startService() and bindService().
>
This is all fine. I have a working example where I use a service and
publish an AIDL. However, it doesn't seem like an efficient way of
designing my service to allow easy integration from third-party
applications (yes, it is a quite rare sort of application). Using
intents would require some re-design, which is fine by me but I'm
looking for the drawback of using this from a performance and power-
consumption point-of-view. Do broadcast intents consume more power
than direct service calls? Does sending, receiving and parsing a
broadcast intent take more CPU than a direct service call?

I know it is a very general question, but I'm assuming there is a
general guideline when to use intents and when to use a service?

// Erik
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to