RequestPermissionsContract

class RequestPermissionsContract(contract: ActivityResultContracts.RequestMultiplePermissions = RequestMultiplePermissions(), permissionFlow: PermissionFlow = PermissionFlow.getInstance()) : ActivityResultContract<Array<String>, Map<String, Boolean>>

An ActivityResultContract which delegates request and response to ActivityResultContracts.RequestMultiplePermissions and silently notifies PermissionFlow regarding state change of a permissions which are requested through ActivityResultLauncher.

Refer to ComponentActivity.registerForPermissionFlowRequestsResult for actual usage.

Constructors

Link copied to clipboard
constructor(contract: ActivityResultContracts.RequestMultiplePermissions = RequestMultiplePermissions(), permissionFlow: PermissionFlow = PermissionFlow.getInstance())

Functions

Link copied to clipboard
open override fun createIntent(context: Context, input: Array<String>): Intent
Link copied to clipboard
open override fun parseResult(resultCode: Int, intent: Intent?): Map<String, Boolean>