How to silence install、update、delete: Difference between revisions

From wizarPOS
(Created page with "Provide the AIDL interface to help the third-party app to implment silence install/uninstall/upload app or reboot device. == Permission == The app declares the follow permissi...")
 
 
(13 intermediate revisions by the same user not shown)
Line 1: Line 1:
Provide the AIDL interface to help the third-party app to implment silence install/uninstall/upload app or reboot device.
Provide the AIDL interface to help the third-party app to implment silence [[#install|install]]/[[#uninstall|uninstall]]/[[#update|update]] app or [[#reboot |reboot]] device.
== Permission ==
== Permission ==
The app declares the follow permission in the manifest.
The app declares the following permission in the manifest.
{| class="wikitable"
{| class="wikitable"
|-
|-
Line 13: Line 13:
|}
|}


== Functions ==
== API Overview==
=== install ===
=== <big>Install</big> ===
  boolean install(String apkPath,String adminPassword);
    <syntaxhighlight lang="java">boolean install(String apkPath,String adminPassword);</syntaxhighlight >
silence install.
Install silently.


'''Parameters'''
{|class="wizarpostable"
|-
! scope="row" colspan="2" | Parameters
|-
| apkPath || '''String:''' the path of the apk.
|-
| adminPassword || '''String:''' the POS adminstrator login password, default is 99999999.
|}
{|
{|
|-
|-
| ''apkPath'' || String || the path of the apk.
|  
|}
{|class="wizarpostable"
|-
|-
| ''adminPassword'' || String || the POS adminstrator login password, default is 99999999.
!  scope="row" colspan="2" | Returns
|-
| boolean || true is success, false is failure.
|}
|}
'''Returns'''
true is success, false is failure.


=== uninstall ===
 
   boolean uninstall(String packageName,String adminPassword);
=== <big>installApkFile</big> ===
silence uninstall
    <syntaxhighlight lang="java">int installApkFile(String apkFilePath);</syntaxhighlight >
'''Parameters'''
Install silently.
 
{|class="wizarpostable"
|-
! scope="row" colspan="2" | Parameters
|-
| apkFilePath || '''String:''' the path of the apk.
|}
{|
|-
|}
{|class="wizarpostable"
|-
!  scope="row" colspan="2" | Returns
|-
|  int || Installation return code, see PackageManager's code. for example: INSTALL_SUCCEEDED = 1.
|}
 
 
=== <big>Uninstall</big> ===
   <syntaxhighlight lang="java">boolean uninstall(String packageName,String adminPassword);</syntaxhighlight >
Uninstalls silently.
{|class="wizarpostable"
|-
! scope="row" colspan="2" | Parameters
|-
| apkPath || '''String:''' the path of the apk.
|-
| adminPassword || '''String:''' the POS adminstrator login password, default is 99999999.
|}
{|
{|
|-
|-
| ''apkPath'' || String || the path of the apk.
|  
|}
{|class="wizarpostable"
|-
!  scope="row" colspan="2" | Returns
|-
|-
| ''adminPassword'' || String ||  the POS adminstrator login password, default is 99999999.
| boolean || true is success, false is failure.
|}
|}
'''Returns'''
true is success, false is failure.


=== update===
 
   boolean update(String apkPath,String adminPassword);
=== <big>Update</big>===
silence update
   <syntaxhighlight lang="java">boolean update(String apkPath,String adminPassword);</syntaxhighlight >
'''Parameters'''
Updates silently.
{|class="wizarpostable"
|-
! scope="row" colspan="2" | Parameters
|-
| apkPath || '''String:''' the path of the apk.
|-
| adminPassword || '''String:''' the POS adminstrator login password, default is 99999999.
|}
{|
{|
|-
|-
| ''apkPath'' || String || the path of the apk.
|  
|}
{|class="wizarpostable"
|-
|-
| ''adminPassword'' || String ||  the POS adminstrator login password, default is 99999999.
!  scope="row" colspan="2" | Returns
|-
|  boolean || true is success, false is failure.
|}
 
 
=== <big>Reboot</big>===
  <syntaxhighlight lang="java">boolean reboot(String adminPassword);</syntaxhighlight >
Reboots silently.
{|class="wizarpostable"
|-
! scope="row" colspan="2" | Parameters
|-
| adminPassword || '''String:''' the POS adminstrator login password, default is 99999999.
|}
|}
'''Returns'''
true is success, false is failure.
=== reboot===
  boolean reboot(String adminPassword);
silence reboot
'''Parameters'''
{|
{|
|-
|-
| ''adminPassword'' || String ||  the POS adminstrator login password, default is 99999999.
|  
|}
|}
'''Returns'''
{|class="wizarpostable"
true is success, false is failure.
|-
!  scope="row" colspan="2" | Returns
|-
|  boolean || true is success, false is failure.
|}
 
== Download ==
== Download ==
Please download the [ftp://sdkuser:wizsdkar@ftp.wizarpos.com/Install&update&Uninstall&RebootDemo_as.rar whold project demo]
Please download the [http://ftp.wizarpos.com/advanceSDK/ISystemManagerService.aidl AIDL file]
 
Please download the [https://github.com/SmartPOSSamples/Install-update-Uninstall-RebootDemo_as APP demo]

Latest revision as of 07:50, 20 May 2024

Provide the AIDL interface to help the third-party app to implment silence install/uninstall/update app or reboot device.

Permission

The app declares the following permission in the manifest.

Permission Function
android.permission.CLOUDPOS_INSTALL_SILENCE silence install
android.permission.CLOUDPOS_UNINSTALL_SILENCE silence uninstall
android.permission.CLOUDPOS_REBOOT silence reboot

API Overview

Install

boolean install(String apkPath,String adminPassword);

Install silently.

Parameters
apkPath String: the path of the apk.
adminPassword String: the POS adminstrator login password, default is 99999999.
Returns
boolean true is success, false is failure.


installApkFile

int installApkFile(String apkFilePath);

Install silently.

Parameters
apkFilePath String: the path of the apk.
Returns
int Installation return code, see PackageManager's code. for example: INSTALL_SUCCEEDED = 1.


Uninstall

boolean uninstall(String packageName,String adminPassword);

Uninstalls silently.

Parameters
apkPath String: the path of the apk.
adminPassword String: the POS adminstrator login password, default is 99999999.
Returns
boolean true is success, false is failure.


Update

boolean update(String apkPath,String adminPassword);

Updates silently.

Parameters
apkPath String: the path of the apk.
adminPassword String: the POS adminstrator login password, default is 99999999.
Returns
boolean true is success, false is failure.


Reboot

boolean reboot(String adminPassword);

Reboots silently.

Parameters
adminPassword String: the POS adminstrator login password, default is 99999999.
Returns
boolean true is success, false is failure.

Download

Please download the AIDL file

Please download the APP demo