OSDN Git Service

Add public constant for usage stats app op.
authorDianne Hackborn <hackbod@google.com>
Tue, 2 Sep 2014 17:57:16 +0000 (10:57 -0700)
committerDianne Hackborn <hackbod@google.com>
Tue, 2 Sep 2014 17:57:16 +0000 (10:57 -0700)
Change-Id: Ibc031b50e9fa4f1bd0955e0afd98e8b1bd77b905

api/current.txt
core/java/android/app/AppOpsManager.java

index 9270f8e..23dbd2f 100644 (file)
@@ -3917,6 +3917,7 @@ package android.app {
     field public static final int MODE_IGNORED = 1; // 0x1
     field public static final java.lang.String OPSTR_COARSE_LOCATION = "android:coarse_location";
     field public static final java.lang.String OPSTR_FINE_LOCATION = "android:fine_location";
+    field public static final java.lang.String OPSTR_GET_USAGE_STATS = "android:get_usage_stats";
     field public static final java.lang.String OPSTR_MONITOR_HIGH_POWER_LOCATION = "android:monitor_location_high_power";
     field public static final java.lang.String OPSTR_MONITOR_LOCATION = "android:monitor_location";
   }
index 66928ca..ba9c9d6 100644 (file)
@@ -220,6 +220,9 @@ public class AppOpsManager {
     /** Continually monitoring location data with a relatively high power request. */
     public static final String OPSTR_MONITOR_HIGH_POWER_LOCATION
             = "android:monitor_location_high_power";
+    /** Access to {@link android.app.usage.UsageStatsManager}. */
+    public static final String OPSTR_GET_USAGE_STATS
+            = "android:get_usage_stats";
     /** Activate a VPN connection without user intervention. @hide */
     @SystemApi
     public static final String OPSTR_ACTIVATE_VPN = "android:activate_vpn";
@@ -331,7 +334,7 @@ public class AppOpsManager {
             null,
             OPSTR_MONITOR_LOCATION,
             OPSTR_MONITOR_HIGH_POWER_LOCATION,
-            null,
+            OPSTR_GET_USAGE_STATS,
             null,
             null,
             null,