# Turn Off Terminal API

### Interface and Class Information

* Package Name: 'com.wizarpos.wizarviewagentassistant'
* Class Name: 'com.wizarpos.wizarviewagentassistant.SilenceService'
* Import 'wizarviewagentassistant' when using this interface.

### Required Permissions

Add the following permission to your application's manifest: 'android.permission.CLOUDPOS\_REBOOT'

### API Function

#### Shutdown

{% code overflow="wrap" %}
```java
boolean shutdown(boolean confirm, boolean wait);
```
{% endcode %}

Turns off the terminal. The 'confirm' parameter decides if confirmation is needed, and 'wait' specifies whether to wait for shutdown completion.

| Parameters |                                                                                                                                                                                                        |
| ---------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| confirm    | if true, shows a shutdown confirmation dialog.                                                                                                                                                         |
| wait       | if true, this call waits for the shutdown to complete and does not return, it's sychronized, that means it will not return from this method if set ture. If false, it's asynchronized, it will return. |

| Returns |                                                                                         |
| ------- | --------------------------------------------------------------------------------------- |
| boolean | <p>a boolean representation of the result.</p><p>true if success. false if failure.</p> |

### Resource Download

* AIDL File: Download the necessary [AIDL file](https://ftp.wizarpos.com/advanceSDK/ISystemManagerService.aidl) for implementation.

