summaryrefslogtreecommitdiffstats
path: root/core/java/android/backup/BackupService.java
diff options
context:
space:
mode:
authorChristopher Tate <ctate@google.com>2009-04-30 11:36:21 -0700
committerChristopher Tate <ctate@google.com>2009-04-30 11:36:21 -0700
commita8bf815c6153290b173f34b071dddb0a0034a115 (patch)
tree0fa451a3a1035092ce916e3d6a25b8e8553f03bd /core/java/android/backup/BackupService.java
parent487529a70cd1479ae8d6bbfb356be7e72542c185 (diff)
downloadframeworks_base-a8bf815c6153290b173f34b071dddb0a0034a115.zip
frameworks_base-a8bf815c6153290b173f34b071dddb0a0034a115.tar.gz
frameworks_base-a8bf815c6153290b173f34b071dddb0a0034a115.tar.bz2
Add android.backup.BackupManager
Also tweak the dataChanged() api to have the client supply a package name. We don't necessarily TRUST this, but we use it to narrow the set of packages requesting a backup pass, no longer blithely scheduling a pass for all packages associated with the caller's uid.
Diffstat (limited to 'core/java/android/backup/BackupService.java')
-rw-r--r--core/java/android/backup/BackupService.java13
1 files changed, 13 insertions, 0 deletions
diff --git a/core/java/android/backup/BackupService.java b/core/java/android/backup/BackupService.java
index 5cfa4f2..0fee72c 100644
--- a/core/java/android/backup/BackupService.java
+++ b/core/java/android/backup/BackupService.java
@@ -29,6 +29,19 @@ import android.util.Log;
* This is the central interface between an application and Android's
* settings backup mechanism.
*
+ * In order to use the backup service, your application must implement a
+ * subclass of BackupService, and declare an intent filter
+ * in the application manifest specifying that your BackupService subclass
+ * handles the {link #SERVICE_ACTION} intent action. For example:
+ *
+ * <pre class="prettyprint">
+ * &lt;!-- Use the class "MyBackupService" to perform backups for my app --&gt;
+ * &lt;service android:name=".MyBackupService"&gt;
+ * &lt;intent-filter&gt;
+ * &lt;action android:name="android.service.action.BACKUP"&gt;
+ * &lt;/intent-filter&gt;
+ * &lt;/service&gt;</pre>
+ *
* <p><em>Not hidden but API subject to change and should not be published</em>
*/