com.ardic.android.managers.kioskmode.IKioskModeManager |
Provides a set of APIs for Kiosk Mode configurations.
Kiosk Mode restricts the user access to the device by replacing (or covering) the standard user home screen.
The standard user home screen (Kiosk mode application) is the first activity that is displayed
when the device boots (CATEGORY_HOME
).
Kiosk mode enables lockdown mode prevents the user from subverting the lockdown screen. (e.g. User can not kill the lock down (change the kiosk mode application) or uninstall it )
In addition the Kiosk mode features,
if required, extra functions are available in disableStatusBar(int)
api(s) to restrict status bar items one by one.
Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
int | ALREADY_ACTIVE | There is a user home screen has already activated as kiosk mode app. | |||||||||
int | OPERATION_FAILED_APP_NOT_EXIST | Application does not exist in the system. | |||||||||
int | OPERATION_FAILED_CLEAR_APP | Operation failed while unregistering the app from default user home screen. | |||||||||
int | OPERATION_FAILED_INVALID_APP | Application does not have user home activity ( CATEGORY_HOME ). |
|||||||||
int | OPERATION_FAILED_LOCKDOWN | Operation failed while enabling lockdown for the user home screen. | |||||||||
int | OPERATION_FAILED_SET_APP | Operation failed while registering the app as default user home screen. | |||||||||
int | OPERATION_FAILED_UNLOCK | Operation failed while disabling lockdown for the user home screen. | |||||||||
int | OPERATION_SUCCEEDED | The operation is succesfully completed. |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Clear Kiosk Mode in the device.
| |||||||||||
Returns existing Kiosk mode application package name.
| |||||||||||
Returns whether Kiosk Mode is enabled on device or not.
| |||||||||||
Sets Kiosk Mode in the device.
|
There is a user home screen has already activated as kiosk mode app.
Application does not exist in the system.
Operation failed while unregistering the app from default user home screen.
Application does not have user home activity ( CATEGORY_HOME
).
Operation failed while enabling lockdown for the user home screen.
Operation failed while registering the app as default user home screen.
Operation failed while disabling lockdown for the user home screen.
The operation is succesfully completed.
Clear Kiosk Mode in the device.
Returns | |
---|---|
int |
Following result; OPERATION_SUCCEEDED if
successfully cleared. OPERATION_FAILED_CLEAR_APP
if unregistering the kiosk mode app from default is failed.OPERATION_FAILED_UNLOCK if disable lock down mode of the
kiosk mode app is failed. |
Throws | |
---|---|
AfexException |
Returns existing Kiosk mode application package name.
Returns | |
---|---|
String |
packageName Application package name, null if Kiosk Mode is not active. |
Throws | |
---|---|
AfexException |
Returns whether Kiosk Mode is enabled on device or not.
Returns | |
---|---|
boolean |
true if Kiosk Mode is enabled on the device else false |
Throws | |
---|---|
AfexException |
Sets Kiosk Mode in the device. It sets the standard user home screen with lock down mode
which blocks changing of user home screen apps to another one or uninstalling it from device
until it is cleared by clearKioskMode()
.
Parameters | |
---|---|
packageName |
String :
Application package name |
Returns | |
---|---|
int |
Following results; OPERATION_SUCCEEDED if the
operation succeeds.OPERATION_FAILED_INVALID_APP
if given application does not have activity CATEGORY_HOME
functionality.OPERATION_FAILED_APP_NOT_EXIST if
given application does not exist in the device.ALREADY_ACTIVE if given application already active for
Kioks mode.OPERATION_FAILED_LOCKDOWN if given
application could not be switched to Lockdown mode. |
Throws | |
---|---|
AfexException |