diff options
author | Victoria Lease <violets@google.com> | 2012-10-22 09:30:07 -0700 |
---|---|---|
committer | Victoria Lease <violets@google.com> | 2012-10-22 12:53:32 -0700 |
commit | 2291ca47c763d9c292865ada1450d3a094918882 (patch) | |
tree | 30667eb6c845aae0404d0844f2cb550388a2a504 /location | |
parent | cc0106cd99831ce7d3715e3c85e5b3e6c5c6ca78 (diff) | |
download | frameworks_base-2291ca47c763d9c292865ada1450d3a094918882.zip frameworks_base-2291ca47c763d9c292865ada1450d3a094918882.tar.gz frameworks_base-2291ca47c763d9c292865ada1450d3a094918882.tar.bz2 |
LocationManager javadoc permission fixes
The javadoc mistakenly claimed that GPS and PASSIVE location
providers could be used with ACCESS_COARSE_LOCATION permissions.
That was incorrect, and the javadoc has been amended.
Bug: 7389249
Change-Id: I6f6489bb539679a962c67ae7263857700df33c82
Diffstat (limited to 'location')
-rw-r--r-- | location/java/android/location/LocationManager.java | 32 |
1 files changed, 9 insertions, 23 deletions
diff --git a/location/java/android/location/LocationManager.java b/location/java/android/location/LocationManager.java index 4ad8fd0..59a5624 100644 --- a/location/java/android/location/LocationManager.java +++ b/location/java/android/location/LocationManager.java @@ -72,15 +72,10 @@ import com.android.internal.location.ProviderProperties; * <p class="note">Unless noted, all Location API methods require * the {@link android.Manifest.permission#ACCESS_COARSE_LOCATION} or * {@link android.Manifest.permission#ACCESS_FINE_LOCATION} permissions. - * If your application only has the Coarse permission then it will still - * receive location results, but the update rate will be throttled and - * the exact location will be obfuscated to a coarse level of accuracy. - * - * <p> class="note">Before API level 17, the use of 'fine' location - * providers such as GPS required the fine permission. As of API level - * 17, applications with only the coarse permission may use all providers, - * including GPS, but the locations are obfuscated (made coarse) before - * being sent to the application. + * If your application only has the coarse permission then it will not have + * access to the GPS or passive location providers. Other providers will still + * return location results, but the update rate will be throttled and the exact + * location will be obfuscated to a coarse level of accuracy. */ public class LocationManager { private static final String TAG = "LocationManager"; @@ -109,13 +104,8 @@ public class LocationManager { * * <p>This provider determines location using * satellites. Depending on conditions, this provider may take a while to return - * a location fix. - * - * <p>Before API version 17, this provider required the - * {@link android.Manifest.permission#ACCESS_FINE_LOCATION} permission. - * From API version 17 and onwards, this provider can also be used with - * {@link android.Manifest.permission#ACCESS_COARSE_LOCATION}, however - * the locations returned will be obfuscated to a coarse level of accuracy. + * a location fix. Requires the permission + * {@link android.Manifest.permission#ACCESS_FINE_LOCATION}. * * <p> The extras Bundle for the GPS location provider can contain the * following key/value pairs: @@ -136,13 +126,9 @@ public class LocationManager { * when other applications or services request them without actually requesting * the locations yourself. This provider will return locations generated by other * providers. You can query the {@link Location#getProvider()} method to determine - * the origin of the location update. - * - * <p>Before API version 17, this provider required the - * {@link android.Manifest.permission#ACCESS_FINE_LOCATION} permission. - * From API version 17 and onwards, this provider can also be used with - * {@link android.Manifest.permission#ACCESS_COARSE_LOCATION}, however - * the locations returned will be obfuscated to a coarse level of accuracy. + * the origin of the location update. Requires the permission + * {@link android.Manifest.permission#ACCESS_FINE_LOCATION}, although if the GPS is + * not enabled this provider might only return coarse fixes. * * @deprecated Use {@link LocationRequest} instead, see notes on {@link LocationManager} */ |