diff options
| author | Jeff Sharkey <jsharkey@android.com> | 2012-02-03 14:50:07 -0800 |
|---|---|---|
| committer | Jeff Sharkey <jsharkey@android.com> | 2012-02-03 14:50:13 -0800 |
| commit | 241dde2306202e7655fdf41d5381f2874e47e108 (patch) | |
| tree | a63e0d09610d9a93f71d725789e5dc3da5f75621 /services/java/com/android/server/net/NetworkPolicyManagerService.java | |
| parent | 1c9fcd9086accad30146b7440820ff84d3c77567 (diff) | |
| download | frameworks_base-241dde2306202e7655fdf41d5381f2874e47e108.zip frameworks_base-241dde2306202e7655fdf41d5381f2874e47e108.tar.gz frameworks_base-241dde2306202e7655fdf41d5381f2874e47e108.tar.bz2 | |
Unify shorthand for byte-based units.
Change-Id: If990859dee3f0973e1d4c48f05312c84071b3328
Diffstat (limited to 'services/java/com/android/server/net/NetworkPolicyManagerService.java')
| -rw-r--r-- | services/java/com/android/server/net/NetworkPolicyManagerService.java | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/services/java/com/android/server/net/NetworkPolicyManagerService.java b/services/java/com/android/server/net/NetworkPolicyManagerService.java index 5c9396f..9772d6a 100644 --- a/services/java/com/android/server/net/NetworkPolicyManagerService.java +++ b/services/java/com/android/server/net/NetworkPolicyManagerService.java @@ -48,6 +48,7 @@ import static android.net.NetworkTemplate.MATCH_MOBILE_4G; import static android.net.NetworkTemplate.MATCH_MOBILE_ALL; import static android.net.NetworkTemplate.MATCH_WIFI; import static android.net.NetworkTemplate.buildTemplateMobileAll; +import static android.net.TrafficStats.MB_IN_BYTES; import static android.text.format.DateUtils.DAY_IN_MILLIS; import static com.android.internal.util.Preconditions.checkNotNull; import static com.android.server.NetworkManagementService.LIMIT_GLOBAL_ALERT; @@ -156,10 +157,6 @@ public class NetworkPolicyManagerService extends INetworkPolicyManager.Stub { private static final int VERSION_ADDED_METERED = 4; private static final int VERSION_SPLIT_SNOOZE = 5; - private static final long KB_IN_BYTES = 1024; - private static final long MB_IN_BYTES = KB_IN_BYTES * 1024; - private static final long GB_IN_BYTES = MB_IN_BYTES * 1024; - // @VisibleForTesting public static final int TYPE_WARNING = 0x1; public static final int TYPE_LIMIT = 0x2; |
