ACCESS_FINE_LOCATION权限是否包含ACCESS_COARSE_LOCATION权限
Does ACCESS_FINE_LOCATION permission include ACCESS_COARSE_LOCATION permissons
美好的一天,我想知道用户是否授予应用程序访问 ACCESS_FINE_LOCATION 权限,如果该应用程序也会自动访问 ACCESS_COARSE_LOCATION API 方法
正如您在指南的 LocationManager API and in an older version 中看到的那样:
If you are using both NETWORK_PROVIDER and GPS_PROVIDER, then you need
to request only the ACCESS_FINE_LOCATION permission, because it
includes permission for both providers. (Permission for
ACCESS_COARSE_LOCATION includes permission only for NETWORK_PROVIDER.)
简而言之:是的,如果您已经定义了 ACCESS_FINE_LOCATION,则允许 ACCESS_COARSE_LOCATION。
美好的一天,我想知道用户是否授予应用程序访问 ACCESS_FINE_LOCATION 权限,如果该应用程序也会自动访问 ACCESS_COARSE_LOCATION API 方法
正如您在指南的 LocationManager API and in an older version 中看到的那样:
If you are using both NETWORK_PROVIDER and GPS_PROVIDER, then you need to request only the ACCESS_FINE_LOCATION permission, because it includes permission for both providers. (Permission for ACCESS_COARSE_LOCATION includes permission only for NETWORK_PROVIDER.)
简而言之:是的,如果您已经定义了 ACCESS_FINE_LOCATION,则允许 ACCESS_COARSE_LOCATION。