How to Update User Role Passwords Using API: Difference between revisions
(Created page with "The system provides the AIDL interface to update the user role password. The package name is '''com.wizarpos.wizarviewagentassistant''', and the class name is '''com.wizarpos....") |
|||
Line 30: | Line 30: | ||
=== <big>forceModifyUserPwd</big>=== | === <big>forceModifyUserPwd</big>=== | ||
<syntaxhighlight lang="java">boolean forceModifyUserPwd(String newPwd);</syntaxhighlight> | <syntaxhighlight lang="java">boolean forceModifyUserPwd(String newPwd);</syntaxhighlight> | ||
Modify the user role password. | |||
{|class="wizarpostable" | {|class="wizarpostable" | ||
Line 48: | Line 48: | ||
| boolean || true of false. | | boolean || true of false. | ||
|} | |} | ||
=== <big>enableUserLogin</big> === | === <big>enableUserLogin</big> === |
Revision as of 02:20, 28 September 2023
The system provides the AIDL interface to update the user role password. The package name is com.wizarpos.wizarviewagentassistant, and the class name is com.wizarpos.wizarviewagentassistant.AdminPwdMainService. When the application uses the interface, it must import the package and add permissions to the Android manifest file.
Permission
The application declares the following permissions in the manifest:
* android.permission.USER_PWD * android.permission.USER_PWD_MODIFY
API Overview
isUserPwd
boolean isUserPwd(String pwd);
Check whether the pwd is the user password.
Parameters | |
---|---|
pwd | String: Not null. |
Returns | |
---|---|
boolean | true of false. |
forceModifyUserPwd
boolean forceModifyUserPwd(String newPwd);
Modify the user role password.
Parameters | |
---|---|
newPwd | String: Not null. |
Returns | |
---|---|
boolean | true of false. |
enableUserLogin
boolean enableUserLogin(boolean eneable);
Enable User role.
Parameters | |
---|---|
name | boolean: true to enable, false to disable. |
Returns | |
---|---|
boolean | true of false. |
Snippet code:
<!-- AdminPwdMainService -->
<uses-permission android:name="android.permission.USER_PWD"/>
<uses-permission android:name="android.permission.USER_PWD_MODIFY"/>
boolean result = adminPwdService.forceModifyUserPwd(newPwd);
boolean isUserPwd = adminPwdService.isUserPwd(newPwd);
ComponentName comp = new ComponentName (
"com.wizarpos.wizarviewagentassistant",
"com.wizarpos.wizarviewagentassistant.AdminPwdMainService");
Download
AIDL file
Please download the aidl file