Simplify deallocation/unbinding of services.

Call counts of call services and selectors are kept current during call
and during the outgoing call process. This allows us to unbind simply
when the call-count goes down to 0.

A second optimization that can be made is to remove associated-call
counts from ServiceBinder and use the callIdMapper to maintain counts of
the associated calls. This binds the call count to the mapper items,
however there are two small roadblocks:
1. It isn't as easy to deal with the replace() scenario, but doable
2. The caller-ID mapper implementations between CS and selectors are
   separate and it's nice to keep a single associated count implementation
   for all ServiceBinders...this is also addressable, just not that
   important at the moment.

Change-Id: Ibbf894ed5b7dd9ede1b088e530dd9cc2e0e649c2
10 files changed
tree: 94110f0f792166adc96bd1e0735f01fa90ef64c5
  1. libs/
  2. res/
  3. src/
  4. tests/
  5. .classpath
  6. .project
  7. Android.mk
  8. AndroidManifest.xml