android.permission.ACCESS_FINE_LOCATION

fine (GPS) location

Access fine location sources, such as the Global Positioning System on the phone, where available. Malicious applications can use this to determine where you are and may consume additional battery power. Alternatively, you might want ACCESS_COARSE_LOCATION.

Added in API level 1

Protection level: dangerous

Constant Value: "android.permission.ACCESS_FINE_LOCATION"

1
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>

Since this is a dangerous permission, users can’t deny the app access to location. Sample code to check if permission was granted:

1
2
3
4
5
6
7
8
9
10
11
if (ActivityCompat.checkSelfPermission(this, Manifest.permission.ACCESS_FINE_LOCATION)
!= PackageManager.PERMISSION_GRANTED) {
// Check Permissions Now
ActivityCompat.requestPermissions(this,
new String[]{Manifest.permission.ACCESS_FINE_LOCATION},
REQUEST_LOCATION);
} else {
// permission has been granted, continue as usual
Location myLocation =
LocationServices.FusedLocationApi.getLastLocation(mGoogleApiClient);
}

See also: https://developer.android.com/guide/topics/location/strategies.html