diff options
author | Jeff Sharkey <jsharkey@android.com> | 2011-06-12 21:13:51 -0700 |
---|---|---|
committer | Jeff Sharkey <jsharkey@android.com> | 2011-06-12 23:21:34 -0700 |
commit | 22c055e6424e0e9579711545d8f4800c0f796db8 (patch) | |
tree | 516406d2d05c2f47c7a2645cfa487eec01b504db /core/java/android/net/NetworkPolicyManager.java | |
parent | 4a97122ebf4d92a3f94402041729d77905e6c0c0 (diff) | |
download | frameworks_base-22c055e6424e0e9579711545d8f4800c0f796db8.zip frameworks_base-22c055e6424e0e9579711545d8f4800c0f796db8.tar.gz frameworks_base-22c055e6424e0e9579711545d8f4800c0f796db8.tar.bz2 |
External mutation of full NetworkPolicy set.
Instead of embedding complex template coexistence rules into policy
service, rely on external editors to enforce, and offer atomic
get/set operations for full policy sets.
Generate default mobile policy when none exists, using default of 4GB
warning and cycle reset of current day. Dispatch listener events
through Handler when holding internal lock, and catch CLASS_UNKNOWN
networks in 3G_LOWER template.
Change-Id: I063cf1eaf330e32b75d0697b89fc04488e6dfaea
Diffstat (limited to 'core/java/android/net/NetworkPolicyManager.java')
-rw-r--r-- | core/java/android/net/NetworkPolicyManager.java | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/core/java/android/net/NetworkPolicyManager.java b/core/java/android/net/NetworkPolicyManager.java index 08b1a81..13ece40 100644 --- a/core/java/android/net/NetworkPolicyManager.java +++ b/core/java/android/net/NetworkPolicyManager.java @@ -55,17 +55,17 @@ public class NetworkPolicyManager { } /** {@hide} */ - public void setNetworkPolicy(int networkType, String subscriberId, NetworkPolicy policy) { + public void setNetworkPolicies(NetworkPolicy[] policies) { try { - mService.setNetworkPolicy(networkType, subscriberId, policy); + mService.setNetworkPolicies(policies); } catch (RemoteException e) { } } /** {@hide} */ - public NetworkPolicy getNetworkPolicy(int networkType, String subscriberId) { + public NetworkPolicy[] getNetworkPolicies() { try { - return mService.getNetworkPolicy(networkType, subscriberId); + return mService.getNetworkPolicies(); } catch (RemoteException e) { return null; } |