USE_CREDENTIALS not available in new Android M API

谁说我不能喝 提交于 2019-12-11 05:46:49

问题


While trying new permissions API, notably:

ActivityCompat.checkSelfPermission ActivityCompat.shouldShowRequestPermissionRationale ActivityCompat.requestPermissions

for permission:

android.permission.USE_CREDENTIALS

(whichn is not listed as "normal" permission)

I've received an "unknown permissionn exception".

Is it a bug? Or is USE_CREDENTIALS a normal permission after all?


回答1:


Neither. USE_CREDENTIALS was removed from the Android SDK in Android 6.0. Not only will you not find it in Manifest.permission in the docs, but if you try hunting for it on an Android 6.0 device (by enumerating all permissions via PackageManager), it does not seem to show up.



来源:https://stackoverflow.com/questions/32338764/use-credentials-not-available-in-new-android-m-api

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!