vanniktech / RxPermission

Reactive permissions for Android
http://vanniktech.com
Apache License 2.0
199 stars 27 forks source link

Feature request - RequestEach combined like tbruyelle / RxPermissions #74

Closed merlinJeyakumar closed 4 years ago

merlinJeyakumar commented 4 years ago

when i try to combine multiple permission callback as single, Now I am writing : RealRxPermission.getInstance(application) .requestEach( Manifest.permission.ACCESS_FINE_LOCATION, Manifest.permission.ACCESS_COARSE_LOCATION ).subscribe({ if (it.name() == Manifest.permission.ACCESS_COARSE_LOCATION) { // if granted or denied } })

same way tbruyelle RxPermissions having this feature but havin an issue while using it rxPermissions .requestEachCombined(Manifest.permission.CAMERA, Manifest.permission.READ_PHONE_STATE)

vanniktech commented 4 years ago

.all(permission -> permission.state() == GRANTED) if you want a Single<Boolean> otherwise use Single#toList()

vanniktech commented 4 years ago

There's more history here: https://github.com/vanniktech/RxPermission/pull/52