summaryrefslogtreecommitdiff
path: root/cmds/bmgr
diff options
context:
space:
mode:
authorChristopher Tate <ctate@google.com>2016-06-15 17:38:00 -0700
committerChristopher Tate <ctate@google.com>2016-06-15 17:40:31 -0700
commite227ec61c24c3c33d42de4996d38fc4e44fa5e4d (patch)
tree92a90ccd7b2182e30ffb8a61932556aba1c4405f /cmds/bmgr
parent931a7c03e070fce6d9be40978159c2bfcb2b9e3a (diff)
Let bmgr inspect the set of whitelisted transports
Needed for compliance testing. Bug 29072466 Change-Id: I025058ab9197f9e2db062bf0074e79f1cd04b443
Diffstat (limited to 'cmds/bmgr')
-rw-r--r--cmds/bmgr/src/com/android/commands/bmgr/Bmgr.java19
1 files changed, 19 insertions, 0 deletions
diff --git a/cmds/bmgr/src/com/android/commands/bmgr/Bmgr.java b/cmds/bmgr/src/com/android/commands/bmgr/Bmgr.java
index 69b5a17300de..5bf80765a7de 100644
--- a/cmds/bmgr/src/com/android/commands/bmgr/Bmgr.java
+++ b/cmds/bmgr/src/com/android/commands/bmgr/Bmgr.java
@@ -122,6 +122,11 @@ public final class Bmgr {
return;
}
+ if ("whitelist".equals(op)) {
+ doPrintWhitelist();
+ return;
+ }
+
System.err.println("Unknown command");
showUsage();
}
@@ -604,6 +609,20 @@ public final class Bmgr {
}
}
+ private void doPrintWhitelist() {
+ try {
+ final String[] whitelist = mBmgr.getTransportWhitelist();
+ if (whitelist != null) {
+ for (String transport : whitelist) {
+ System.out.println(transport);
+ }
+ }
+ } catch (RemoteException e) {
+ System.err.println(e.toString());
+ System.err.println(BMGR_NOT_RUNNING_ERR);
+ }
+ }
+
private String nextArg() {
if (mNextArg >= mArgs.length) {
return null;