Control the shutdown and reboot of the target.
Methods
-
reboot(successCallback, errorCallbackopt, reasonopt, fast)
-
Initiate a reboot request.Parameters:
Name Type Attributes Description successCallbackfunction The function to call when successful. errorCallbackfunction <optional>
The function to call if there is an error. reasonString <optional>
The zone to filter the results by. fastString Whether to use fast or slow reboot. Set to "1" for fast reboot (without logging), otherwise set to "0" for slow reboot (with with logging). Example
//define your callback function(s) function successCallback(audioMixerItems) { console.log("Shutdown Initiated") } function errorCallback(error) { console.log(error.code, error.msg); } //call the method qnx.power.reboot(successCallback, errorCallback, "userRequest","1"); -
shutdown(successCallback, errorCallbackopt, reasonopt, fast)
-
Initiate a shutdown request.Parameters:
Name Type Attributes Description successCallbackfunction The function to call when successful. errorCallbackfunction <optional>
The function to call if there's an error. reasonString <optional>
The zone to filter the results by. fastString Whether to use fast or slow shutdown. Set to "1" for fast shutdown(without logging), otherwise set to "0" for slow showdown (with with logging). Example
//define your callback function(s) function successCallback(audioMixerItems) { console.log("Shutdown Initiated") } function errorCallback(error) { console.log(error.code, error.msg); } //call the method qnx.power.shutdown(successCallback, errorCallback, "userRequest","1");