summaryrefslogtreecommitdiffstats
path: root/cmds/bmgr/src
diff options
context:
space:
mode:
authorJoe Onorato <joeo@android.com>2009-06-25 21:34:49 -0400
committerJoe Onorato <joeo@android.com>2009-06-25 21:34:49 -0400
commit5e8a4b842c20dd47b82e9915f1bd730ee1b0d46d (patch)
tree7408bf959f58575cb3e991ca72b3b9a6bb39f72c /cmds/bmgr/src
parent7d562ec393d54dd9ef387c49d1283243bfdbd2b1 (diff)
downloadframeworks_base-5e8a4b842c20dd47b82e9915f1bd730ee1b0d46d.zip
frameworks_base-5e8a4b842c20dd47b82e9915f1bd730ee1b0d46d.tar.gz
frameworks_base-5e8a4b842c20dd47b82e9915f1bd730ee1b0d46d.tar.bz2
Give the bmgr command an IRestoreObserver too.
Diffstat (limited to 'cmds/bmgr/src')
-rw-r--r--cmds/bmgr/src/com/android/commands/bmgr/Bmgr.java15
1 files changed, 13 insertions, 2 deletions
diff --git a/cmds/bmgr/src/com/android/commands/bmgr/Bmgr.java b/cmds/bmgr/src/com/android/commands/bmgr/Bmgr.java
index 841e3df..8745cff 100644
--- a/cmds/bmgr/src/com/android/commands/bmgr/Bmgr.java
+++ b/cmds/bmgr/src/com/android/commands/bmgr/Bmgr.java
@@ -17,6 +17,7 @@
package com.android.commands.bmgr;
import android.backup.IBackupManager;
+import android.backup.IRestoreObserver;
import android.backup.IRestoreSession;
import android.backup.RestoreSet;
import android.os.RemoteException;
@@ -34,6 +35,16 @@ public final class Bmgr {
private String[] mArgs;
private int mNextArg;
private String mCurArgData;
+ private RestoreObserver mObserver = new RestoreObserver();
+
+ class RestoreObserver extends IRestoreObserver.Stub {
+ public void restoreStarting(int numPackages) {
+ }
+ public void onUpdate(int nowBeingRestored) {
+ }
+ public void restoreFinished(int error) {
+ }
+ }
public static void main(String[] args) {
try {
@@ -200,7 +211,7 @@ public final class Bmgr {
for (RestoreSet s : sets) {
if (s.token == token) {
System.out.println("Scheduling restore: " + s.name);
- mRestore.performRestore(token);
+ mRestore.performRestore(token, mObserver);
break;
}
}
@@ -229,4 +240,4 @@ public final class Bmgr {
System.err.println(" bmgr restore token#");
System.err.println(" bmgr run");
}
-} \ No newline at end of file
+}