AI2 Component  (Version nb184)
com.google.appinventor.components.runtime.errors.PermissionException Class Reference
Inheritance diagram for com.google.appinventor.components.runtime.errors.PermissionException:

Public Member Functions

 PermissionException (String permissionNeeded)
 
String getPermissionNeeded ()
 
String getMessage ()
 

Detailed Description

PermissionException is thrown when App Inventor needs a certain permission granted by the user but does not have that permissions according to the Android permissions API.

This exception will only be thrown on SDK 23 (Android 6.0 Marshmallow) or higher.

Author
ewpat.nosp@m.ton@.nosp@m.mit.e.nosp@m.du (Evan W. Patton)

Definition at line 16 of file PermissionException.java.

Constructor & Destructor Documentation

◆ PermissionException()

com.google.appinventor.components.runtime.errors.PermissionException.PermissionException ( String  permissionNeeded)

Construct a new PermissionException to report that the given permission is needed.

Parameters
permissionNeededThe permission needed at the point the exception is thrown.

Definition at line 24 of file PermissionException.java.

Member Function Documentation

◆ getMessage()

String com.google.appinventor.components.runtime.errors.PermissionException.getMessage ( )

Definition at line 37 of file PermissionException.java.

◆ getPermissionNeeded()

String com.google.appinventor.components.runtime.errors.PermissionException.getPermissionNeeded ( )

Get the name of the needed permission.

Returns
The permission name, e.g. android.permission.WRITE_EXTERNAL_STORAGE

Definition at line 32 of file PermissionException.java.


The documentation for this class was generated from the following file: