Skip to content

Instantly share code, notes, and snippets.

@NewtronLabs
Created May 18, 2019 02:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save NewtronLabs/ff63cab1e1354ac3f46f1633007ece0f to your computer and use it in GitHub Desktop.
Save NewtronLabs/ff63cab1e1354ac3f46f1633007ece0f to your computer and use it in GitHub Desktop.
Easy Permissions Example 1 Java
public class ExampleService extends Service implements IPermissionsListener {
@Override
public void onCreate() {
super.onCreate();
// Will request all permissions from the Manifest automatically.
EasyPermissions.getInstance().requestPermissions(this);
}
@Override
public void onCompleted(Set<String> grantedPermissions, Set<String> deniedPermissions) {}
@Override
public void onFailure(Throwable throwable) {}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment