Bumping gaia.json for 2 gaia revision(s) a=gaia-bump
[gecko.git] / hal / gonk / nsIRecoveryService.idl
blobecbb39c0e1bcea3d255ca93c04331e7001b3c21f
1 /* This Source Code Form is subject to the terms of the Mozilla Public
2 * License, v. 2.0. If a copy of the MPL was not distributed with this file,
3 * You can obtain one at http://mozilla.org/MPL/2.0/. */
5 #include "nsISupports.idl"
7 [scriptable, uuid(bc24fb33-a0c1-49ca-aa43-05f167e02fb6)]
8 interface nsIRecoveryService : nsISupports
10 /**
11 * Possible values of fotaStatus.result. These should stay in sync with
12 * librecovery/librecovery.h
14 const long FOTA_UPDATE_UNKNOWN = 0;
15 const long FOTA_UPDATE_FAIL = 1;
16 const long FOTA_UPDATE_SUCCESS = 2;
18 /**
19 * Uses recovery to wipe the data and cache partitions. If this call is
20 * successful, the device should reboot before the function call ever returns.
22 * @throws NS_ERROR_FAILURE when rebooting into recovery fails for some reason.
24 void factoryReset(in string reason);
26 /**
27 * Use recovery to install an OTA update.zip. If this call is
28 * successful, the device should reboot before the function call ever returns.
30 * @throws NS_ERROR_FAILURE when rebooting into recovery fails for some reason.
32 void installFotaUpdate(in string updatePath);
34 /**
35 * @return The status of the last FOTA update. One of FOTA_UPDATE_UNKNOWN,
36 * FOTA_UPDATE_FAIL, FOTA_UPDATE_SUCCESS.
38 long getFotaUpdateStatus();