Merge "Document startService cost" into nyc-dev

am: 6ed4e35

* commit '6ed4e35e49fb9d1e485f53b4ce309865d98a6058':
  Document startService cost

Change-Id: Iee9832e83570b01c98b72ce46a500b61b3184036
This commit is contained in:
Chris Craik
2016-04-19 21:19:57 +00:00
committed by android-build-merger

View File

@@ -2446,6 +2446,15 @@ public abstract class Context {
* <p>This function will throw {@link SecurityException} if you do not
* have permission to start the given service.
*
* <p class="note"><strong>Note:</strong> Each call to startService()
* results in significant work done by the system to manage service
* lifecycle surrounding the processing of the intent, which can take
* multiple milliseconds of CPU time. Due to this cost, startService()
* should not be used for frequent intent delivery to a service, and only
* for scheduling significant work. Use {@link #bindService bound services}
* for high frequency calls.
* </p>
*
* @param service Identifies the service to be started. The Intent must be either
* fully explicit (supplying a component name) or specify a specific package
* name it is targetted to. Additional values