Declaring Permission
Permission Overview
The permission required to call each FusedLocation API can be found on the corresponding API details page in the FusedLocation API Reference. The permission currently defined is pleos.car.permission.FUSED_LOCATION.
| Permission | Protection level | APIs |
|---|---|---|
pleos.car.permission.FUSED_LOCATION | dangerous | getLastKnownLocation, registerFusedLocationCallback, unregisterFusedLocationCallback |
Declaring the Permission in AndroidManifest.xml
Declare the following permission in AndroidManifest.xml before calling location APIs in the FusedLocation SDK.
<manifest ...>
<uses-permission android:name="pleos.car.permission.FUSED_LOCATION" />
<application ... />
</manifest>
If the permission is not granted, APIs that require it may not work as expected. Implement permission requests and result handling according to your app's permission flow.
Location Access Blocked State
If location access is blocked by the vehicle's current privacy settings, call showLocationAccessBlockedPopup() to inform the user that access is blocked.
This API does not grant location access. If location data is not delivered, handle both null in the callback and onError(Exception), and appropriately restrict the app's screens and features.
The behavior of Android ACCESS_COARSE_LOCATION, ACCESS_FINE_LOCATION, and ACCESS_BACKGROUND_LOCATION, including foreground and background location access policies, is not separately guaranteed in this SDK documentation. Do not interpret Google Fused Location SDK documentation as a guarantee of Pleos Connect behavior.