Is there any way for permission state change detection in Android Marshmallow?
I have not seen broadcast for that...
Is there any way for permission state change detection in Android Marshmallow?
I have not seen broadcast for that...
Permissions cannot change in the middle of the app. If an permission is changed -> the app is restarted. There is no Broadcast - you have to check every-time - but it is OK to only do it at startup of your app
No. You will not get any broadcast for it. On each call of a feature, which needs permission, you need to check if permission is granted or not.
Read Request App Permissions, a well documented, and covers each point which you need to take care of. It seems Google has achieved the official sample, but still, you can find some useful information from the sample. And at last watch Android Marshmallow 6.0: Asking For Permission to design your app in a better way.
Note:
Also read, Permissions updates in Android 11,
You have to check permission each and every time whenever you use. For your simplicity you can use PermissionAcceptor-master library.