Android Library for Easily calling Runtime Permission on Android Marshmallow and above

Overview

Android Arsenal Release

Note: Deprecated as the new way of requesting permission is quite straightforward

PermissionMadeEasy

Android Library for Easily calling Runtime Permission on Android Marshmallow and above

How to build

Add Jitpack.io to your project level build.gradle file

allprojects {
    repositories {
        maven { url 'https://jitpack.io' }
    }
}

Add the dependency

dependencies {
	  implementation 'com.github.thesomeshkumar:permissionmadeeasy:1.2.3'
	}

How to use

Create a PermissionHelper object

permissionHelper = PermissionHelper.Builder()
        .with(this)
        .requestCode(REQUEST_CODE_MULTIPLE)
        .setPermissionResultCallback(this)
        .askFor(Permission.CALENDAR, Permission.CAMERA, Permission.CONTACTS,
                Permission.LOCATION, Permission.MICROPHONE, Permission.STORAGE,
                Permission.PHONE, Permission.SMS, Permission.SENSORS)
        .rationalMessage("Permissions are required for app to work properly")
        .build()

and when you want to ask for the permission just call

permissionHelper.requestPermissions()

Override onPermissionsGranted and onPermissionsDenied functions

Also override onRequestPermissionsResult and pass the arguments recieved to PermissionHelper class' onRequestPermissionsResult function.

@Override
    public void onRequestPermissionsResult(int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) {
        super.onRequestPermissionsResult(requestCode, permissions, grantResults);
        permissionHelper.onRequestPermissionsResult(requestCode, permissions, grantResults);
    }

Detailed full sample project is included. Check DemoActivity for full implemetation

You might also like...
A react-like kotlin library to create an inventory ui easily in paper plugins
A react-like kotlin library to create an inventory ui easily in paper plugins

A react-like kotlin library to create an inventory ui easily in paper plugins

A Gradle plugin to easily publish library components to Maven.
A Gradle plugin to easily publish library components to Maven.

Component Publisher A Gradle plugin to easily publish components based on maven-publish. You can find the latest released plugin on Gradle Plugin Port

A Kotlin Multiplatform and Compose template that allows you to easily set up your project targeting: Android, Desktop, and Web

A Kotlin Multiplatform and Compose template that allows you to easily set up your project targeting: Android, Desktop, and Web

Kotlin and Ktor app, which can easily be deployed to Heroku

[ 🚧 Work in progress 👷‍♀️ ⛏ 👷 🔧️ 👷 🔧 🚧 ] Shoppe Kotlin Multiplatform App Kotlin and Ktor app, which can easily be deployed to Heroku. This appl

With MaterialTimelineView you can easily create a material looking timeline.
With MaterialTimelineView you can easily create a material looking timeline.

MaterialTimelineView With MaterialTimelineView you can easily create a material looking timeline. Setup The library is pushed to jCenter() as an AAR,

Quick route to developer options page easily
Quick route to developer options page easily

QuickRoute Using Quick Settings Tile to navigate to Developer options page without click a lot of buttons. Preview Install Can install from Google Pla

Arrow Endpoint offers a composable Endpoint datatype, that allows us easily define an Endpoint from which we can derive clients, servers & documentation.

Arrow Endpoint Arrow Endpoint offers a composable Endpoint datatype, that allows us easily define an Endpoint from which we can derive clients, server

Arrow Endpoint offers a composable Endpoint datatype, that allows us easily define an Endpoint from which we can derive clients, servers & documentation.

Arrow Endpoint Arrow Endpoint offers a composable Endpoint datatype, that allows us easily define an Endpoint from which we can derive clients, server

A tiny Kotlin multiplatform library that assists in saving and restoring objects to and from disk using kotlinx.coroutines, kotlinx.serialisation and okio

Store A tiny Kotlin multiplatform library that assists in saving and restoring objects to and from disk using kotlinx.coroutines, kotlinx.serialisatio

Releases(1.2.3)
Owner
Somesh Kumar
No Biohazard
Somesh Kumar
Android sliding panel that is part of the view hierarchy, not above it.

sliding-panel A ViewGroup that implements a sliding panel that is part of the view hierarchy, not above it. Difference from other libraries All other

Pierfrancesco Soffritti 441 Nov 12, 2022
Permissionmanager is a small wrapper for handling permission requests.

Permissionmanager Permissionmanager is a small wrapper for handling permission requests. Installation Add jitpack to your repositories in Project buil

Thomas Cirksena 11 Nov 17, 2020
:closed_umbrella: An easy way to implement modern permission instructions popup.

Needs An easy way to implement modern permission instructions popup. Needs can be fully customized and showing with animations. Download Gradle Add be

Jaewoong Eum 609 Dec 8, 2022
This is a Kotlin multiplatform template project used to generate and deploy a natively compiled AWS lambda function using the custom runtime.

Overview This is a Kotlin multiplatform template project used to generate and deploy a natively compiled AWS Lambda function using a custom runtime. U

Greg Steckman 5 Jun 25, 2022
🍼Debug Bottle is an Android runtime debug / develop tools written using kotlin language.

???? 中文 / ???? 日本語 / ???? English ?? Debug Bottle An Android debug / develop tools written using Kotlin language. All the features in Debug bottle are

Yuriel Arlencloyn 846 Nov 14, 2022
An experimental tool for building console UI in Kotlin using the Jetpack Compose compiler/runtime

An experimental tool for building console UI in Kotlin using the Jetpack Compose compiler/runtime

Jake Wharton 1.4k Dec 28, 2022
Kotlin Multiplatform runtime infix expressions evaluator.

Kotlin multiplatform expressions evaluator This is a kotlin multiplatform runtime infix expressions evaluator. Overview Operators The library supports

Azamat Murzagalin 13 Dec 30, 2022
[Android Library] A SharedPreferences helper library to save and fetch the values easily.

Preference Helper A SharedPreferences helper library to save and fetch the values easily. Featured in Use in your project Add this to your module's bu

Naveen T P 13 Apr 4, 2020
This library is a set of simple wrapper classes that are aimed to help you easily access android device information.

SysInfo Simple, single class wrapper to get device information from an android device. This library provides an easy way to access all the device info

Klejvi Kapaj 7 Dec 27, 2022