Searched refs:NetworkState (Results 1 - 25 of 28) sorted by relevance

12

/frameworks/base/core/java/android/net/
H A DNetworkState.aidl19 parcelable NetworkState;
H A DNetworkState.java28 public class NetworkState implements Parcelable { class in inherits:Parcelable
31 public static final NetworkState EMPTY = new NetworkState(null, null, null, null, null, null);
40 public NetworkState(NetworkInfo networkInfo, LinkProperties linkProperties, method in class:NetworkState
55 Slog.wtf("NetworkState", "Roaming state disagreement between " + networkInfo
61 public NetworkState(Parcel in) { method in class:NetworkState
85 public static final Creator<NetworkState> CREATOR = new Creator<NetworkState>() {
87 public NetworkState createFromParcel(Parcel in) {
88 return new NetworkState(i
[all...]
H A DINetworkPolicyManager.aidl22 import android.net.NetworkState;
67 NetworkQuotaInfo getNetworkQuotaInfo(in NetworkState state);
H A DIConnectivityManager.aidl27 import android.net.NetworkState;
65 NetworkState[] getAllNetworkState();
H A DNetworkIdentity.java193 * Build a {@link NetworkIdentity} from the given {@link NetworkState},
196 public static NetworkIdentity buildNetworkIdentity(Context context, NetworkState state,
/frameworks/support/work/workmanager/src/main/java/androidx/work/impl/constraints/controllers/
H A DNetworkConnectedController.java25 import androidx.work.impl.constraints.NetworkState;
32 * For API 26 and above, usable means that the {@link NetworkState} is validated, i.e.
35 * For API 25 and below, usable simply means that {@link NetworkState} is connected.
38 public class NetworkConnectedController extends ConstraintController<NetworkState> {
49 boolean isConstrained(@NonNull NetworkState state) {
H A DNetworkMeteredController.java26 import androidx.work.impl.constraints.NetworkState;
34 public class NetworkMeteredController extends ConstraintController<NetworkState> {
51 boolean isConstrained(@NonNull NetworkState state) {
H A DNetworkNotRoamingController.java26 import androidx.work.impl.constraints.NetworkState;
34 public class NetworkNotRoamingController extends ConstraintController<NetworkState> {
51 boolean isConstrained(@NonNull NetworkState state) {
H A DNetworkUnmeteredController.java24 import androidx.work.impl.constraints.NetworkState;
32 public class NetworkUnmeteredController extends ConstraintController<NetworkState> {
43 boolean isConstrained(@NonNull NetworkState state) {
/frameworks/support/work/workmanager/src/main/java/androidx/work/impl/constraints/
H A DNetworkState.java23 public class NetworkState { class
30 public NetworkState(boolean isConnected, boolean isValidated, boolean isMetered, method in class:NetworkState
82 NetworkState other = (NetworkState) o;
/frameworks/base/services/core/java/com/android/server/connectivity/tethering/
H A DTetheringInterfaceUtils.java22 import android.net.NetworkState;
38 public static @Nullable InterfaceSet getTetheringInterfaces(NetworkState ns) {
54 public static @Nullable String getIPv6Interface(NetworkState ns) {
H A DUpstreamNetworkMonitor.java36 import android.net.NetworkState;
92 private final HashMap<Network, NetworkState> mNetworkMap = new HashMap<>();
199 // Next TODO: return NetworkState instead of just the type.
200 public NetworkState selectPreferredUpstreamType(Iterable<Integer> preferredTypes) {
241 new NetworkState(null, null, null, network, null, null));
302 final NetworkState prev = mNetworkMap.get(network);
322 mNetworkMap.put(network, new NetworkState(
330 final NetworkState prev = mNetworkMap.get(network);
343 mNetworkMap.put(network, new NetworkState(
464 public NetworkState n
[all...]
H A DIPv6TetheringCoordinator.java25 import android.net.NetworkState;
75 private NetworkState mUpstreamNetworkState;
116 public void updateUpstreamNetworkState(NetworkState ns) {
141 private void setUpstreamNetworkState(NetworkState ns) {
146 mUpstreamNetworkState = new NetworkState(
297 private static String toDebugString(NetworkState ns) {
299 return "NetworkState{null}";
301 return String.format("NetworkState{%s, %s, %s}",
/frameworks/support/work/workmanager/src/androidTest/java/androidx/work/impl/constraints/trackers/
H A DNetworkStateTrackerTest.java34 import androidx.work.impl.constraints.NetworkState;
65 NetworkState expectedState = new NetworkState(false, false, true, false);
73 NetworkState expectedState = new NetworkState(false, false, false, false);
/frameworks/support/work/workmanager/src/main/java/androidx/work/impl/constraints/trackers/
H A DNetworkStateTracker.java33 import androidx.work.impl.constraints.NetworkState;
49 public class NetworkStateTracker extends ConstraintTracker<NetworkState> {
74 public NetworkState getInitialState() {
106 private NetworkState getActiveNetworkState() {
113 return new NetworkState(isConnected, isValidated, isMetered, isNotRoaming);
/frameworks/base/tests/net/java/com/android/server/connectivity/
H A DTetheringTest.java74 import android.net.NetworkState;
243 private static NetworkState buildMobileUpstreamState(boolean withIPv4, boolean withIPv6,
276 return new NetworkState(info, prop, capabilities, new Network(100), null, "netid");
279 private static NetworkState buildMobileIPv4UpstreamState() {
283 private static NetworkState buildMobileIPv6UpstreamState() {
287 private static NetworkState buildMobileDualStackUpstreamState() {
291 private static NetworkState buildMobile464xlatUpstreamState() {
460 private void prepareUsbTethering(NetworkState upstreamState) {
474 NetworkState upstreamState = buildMobileIPv4UpstreamState();
549 private void sendIPv6TetherUpdates(NetworkState upstreamStat
[all...]
/frameworks/base/core/tests/bandwidthtests/src/com/android/bandwidthtest/
H A DNetworkState.java28 public class NetworkState { class
35 private final String LOG_TAG = "NetworkState";
41 public NetworkState() { method in class:NetworkState
47 public NetworkState(State currentState) { method in class:NetworkState
/frameworks/base/services/core/java/com/android/server/connectivity/
H A DNetworkAgentInfo.java28 import android.net.NetworkState;
471 public NetworkState getNetworkState() {
476 return new NetworkState(new NetworkInfo(networkInfo),
H A DTethering.java76 import android.net.NetworkState;
1170 private boolean pertainsToCurrentUpstream(NetworkState ns) {
1353 final NetworkState ns = mUpstreamNetworkMonitor.selectPreferredUpstreamType(
1367 protected void setUpstreamNetwork(NetworkState ns) {
1383 // If we already have NetworkState for this network examine
1422 protected void handleNewUpstreamNetworkState(NetworkState ns) {
1482 final NetworkState ns = (NetworkState) o;
1758 public void updateUpstreamNetworkState(NetworkState ns) {
2012 private static String getIPv4DefaultRouteInterface(NetworkState n
[all...]
/frameworks/base/core/tests/bandwidthtests/src/com/android/bandwidthtest/util/
H A DConnectionUtil.java43 import com.android.bandwidthtest.NetworkState;
44 import com.android.bandwidthtest.NetworkState.StateTransitionDirection;
80 private NetworkState[] mConnectivityState = new NetworkState[NUM_NETWORK_TYPES];
256 mConnectivityState[networkType] = new NetworkState();
/frameworks/base/tests/net/java/com/android/server/net/
H A DNetworkStatsServiceTest.java81 import android.net.NetworkState;
704 final NetworkState wifiState = buildWifiState();
1084 private void expectNetworkState(NetworkState... state) throws Exception {
1227 private static NetworkState buildWifiState() {
1231 private static NetworkState buildWifiState(boolean isMetered) {
1239 return new NetworkState(info, prop, capabilities, WIFI_NETWORK, null, TEST_SSID);
1242 private static NetworkState buildMobile3gState(String subscriberId) {
1246 private static NetworkState buildMobile3gState(String subscriberId, boolean isRoaming) {
1256 return new NetworkState(info, prop, capabilities, MOBILE_NETWORK, subscriberId, null);
1259 private static NetworkState buildMobile4gStat
[all...]
/frameworks/base/services/tests/servicestests/src/com/android/server/
H A DNetworkPolicyManagerServiceTest.java103 import android.net.NetworkState;
966 NetworkState[] state = null;
978 state = new NetworkState[] { buildWifi() };
1214 NetworkState[] state = null;
1224 state = new NetworkState[] { buildWifi() };
1351 when(mConnManager.getAllNetworkState()).thenReturn(new NetworkState[0]);
1362 when(mConnManager.getAllNetworkState()).thenReturn(new NetworkState[0]);
1716 private static NetworkState buildWifi() {
1722 return new NetworkState(info, prop, networkCapabilities, null, null, TEST_SSID);
1733 when(mConnManager.getAllNetworkState()).thenReturn(new NetworkState[] {
[all...]
/frameworks/base/services/core/java/com/android/server/
H A DConnectivityService.java75 import android.net.NetworkState;
1025 private NetworkState getFilteredNetworkState(int networkType, int uid, boolean ignoreBlocked) {
1028 final NetworkState state;
1040 state = new NetworkState(info, new LinkProperties(), capabilities,
1046 return NetworkState.EMPTY;
1076 private NetworkState getUnfilteredActiveNetworkState(int uid) {
1096 return NetworkState.EMPTY;
1144 * Apply any relevant filters to {@link NetworkState} for the given UID. For
1148 private void filterNetworkStateForUid(NetworkState state, int uid, boolean ignoreBlocked) {
1172 final NetworkState stat
[all...]
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/mocks/
H A DConnectivityServiceMock.java35 import android.net.NetworkState;
488 public NetworkState[] getAllNetworkState() {
/frameworks/base/services/core/java/com/android/server/net/
H A DNetworkPolicyManagerService.java155 import android.net.NetworkState;
1713 * Collect all ifaces from a {@link NetworkState} into the given set.
1715 private static void collectIfaces(ArraySet<String> ifaces, NetworkState state) {
1769 * Examine all connected {@link NetworkState}, looking for
1777 final NetworkState[] states;
1788 final ArrayMap<NetworkState, NetworkIdentity> identified = new ArrayMap<>();
1789 for (NetworkState state : states) {
1871 for (NetworkState state : states) {
1905 for (NetworkState state : states) {
2927 public NetworkQuotaInfo getNetworkQuotaInfo(NetworkState stat
[all...]

Completed in 162 milliseconds

12