JetradarMobile / Mrbutler
Licence: apache-2.0
Reactive Android App Permissions API with delegates and logging
Stars: ✭ 77
Programming Languages
kotlin
9241 projects
Projects that are alternatives of or similar to Mrbutler
Kpermissions
A Kotlin library which helps to request runtime permissions in Android.
Stars: ✭ 253 (+228.57%)
Mutual labels: rxjava, permissions
Rxpermission
Reactive permissions for Android
Stars: ✭ 182 (+136.36%)
Mutual labels: rxjava, permissions
Logbert
Logbert is an advanced log message viewer for log4net, log4j and others.
Stars: ✭ 70 (-9.09%)
Mutual labels: logging
Ziggurat foundations
Framework agnostic set of sqlalchemy classes that make building applications that require permissions an easy task.
Stars: ✭ 67 (-12.99%)
Mutual labels: permissions
Android Mvp Starter
Create/Generate your MVP projects easily
Stars: ✭ 72 (-6.49%)
Mutual labels: rxjava
Logging Log4j2
Apache Log4j 2 is an upgrade to Log4j that provides significant improvements over its predecessor, Log4j 1.x, and provides many of the improvements available in Logback while fixing some inherent problems in Logback's architecture.
Stars: ✭ 1,133 (+1371.43%)
Mutual labels: logging
Rxjavajdk8interop
RxJava 2/3 interop library for supporting Java 8 features such as Optional, Stream and CompletableFuture [discontinued]
Stars: ✭ 70 (-9.09%)
Mutual labels: rxjava
Simplenews.io
🏸 A news App,based on the RxJava 、MVP. 基于MVP、RxJava 、Android 组件化的新闻博客客户端.
Stars: ✭ 74 (-3.9%)
Mutual labels: rxjava
Sejil
Capture, view and filter your ASP.net core log events right from your app
Stars: ✭ 70 (-9.09%)
Mutual labels: logging
Rxbluetoothkotlin
Bluetooth low energy reactive framework for Android written in Kotlin
Stars: ✭ 68 (-11.69%)
Mutual labels: rxjava
Ring Logger
Log ring requests & responses using your favorite logging backend
Stars: ✭ 66 (-14.29%)
Mutual labels: logging
Rxkotlinfx Tornadofx Demo
A demo application demonstrating TornadoFX and Rx usage
Stars: ✭ 75 (-2.6%)
Mutual labels: rxjava
Litter
Litter is a pretty printer library for Go data structures to aid in debugging and testing.
Stars: ✭ 1,137 (+1376.62%)
Mutual labels: logging
Android Filelogger
A general-purpose logging library with built-in support to save logs to file efficiently.
Stars: ✭ 70 (-9.09%)
Mutual labels: logging
Android Mvvm Rx3 Dagger2 Navcomponent
Implemented using MVVM, LiveData, Room, RX3, Dagger2, Coil, View Binding, Navigation Component and AndroidX
Stars: ✭ 72 (-6.49%)
Mutual labels: rxjava
Laravel Log To Db
Custom Laravel and Lumen 5.6+ Log channel handler that can store log events to SQL or MongoDB databases. Uses Laravel/Monolog native logging functionality.
Stars: ✭ 76 (-1.3%)
Mutual labels: logging
MrButler
Reactive Android App Permissions API with delegates and logging.
API | Description |
---|---|
request(vararg permissions: String) |
emit true if all requested permissions granted |
requestSingle(permission: String) |
emit result of permission request |
requestEach(vararg permissions: String) |
emit results for each permission request |
check(vararg permissions: String) |
emit true if all permissions already granted |
checkSingle(permission: String) |
emit result of availability check permission |
checkEach(vararg permissions: String) |
emit result of availability check each permission |
require(vararg permissions: String) |
throw PermissionsDeniedException if permission denied |
Download
Add it in your root build.gradle at the end of repositories:
allprojects {
repositories {
...
maven { url "https://jitpack.io" }
}
}
Add the dependency
dependencies {
compile 'com.github.jetradarmobile:mrbutler:1.0.3'
}
Usage
Request LOCATION permission
mrButler(activity)
.request(Manifest.permission.ACCESS_FINE_LOCATION)
.subscribe { granted -> ... }
A feature of this implementation is Delegates
. Using delegates you can request permission anywhere.
Initialize MrButler
class App : Application() {
val permissionsActivityDelegate = PermissionsActivityDelegate()
val mrButler = MrButler(permissionsActivityDelegate) { message ->
Log.i("Permissions", message)
}
override fun onCreate() {
super.onCreate()
instance = this
}
companion object {
lateinit var instance: App
}
}
Associate the permissions delegate with activity
class MainActivity : AppCompatActivity() {
private val permissionsDelegate = App.instance.permissionsActivityDelegate
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
permissionsDelegate.attach(this)
// ...
}
override fun onRequestPermissionsResult(requestCode: Int, permissions: Array<out String>, grantResults: IntArray) {
super.onRequestPermissionsResult(requestCode, permissions, grantResults)
permissionsDelegate.onRequestPermissionsResult(requestCode, permissions, grantResults)
}
override fun onDestroy() {
super.onDestroy()
permissionsDelegate.detach()
}
}
Request permissions anywhere
App.instance.mrButler
.request(Manifest.permission.ACCESS_FINE_LOCATION)
.subscribe { granted -> ... }
License
Copyright 2018 JetRadar
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].