Home
last modified time | relevance | path

Searched refs:hasTransport (Results 1 – 25 of 52) sorted by relevance

123

/packages/modules/NetworkStack/src/com/android/networkstack/metrics/
DNetworkValidationMetrics.java94 boolean hasCellular = nc.hasTransport(TRANSPORT_CELLULAR); in getTransportTypeFromNC()
95 boolean hasWifi = nc.hasTransport(TRANSPORT_WIFI); in getTransportTypeFromNC()
96 boolean hasBT = nc.hasTransport(TRANSPORT_BLUETOOTH); in getTransportTypeFromNC()
97 boolean hasEthernet = nc.hasTransport(TRANSPORT_ETHERNET); in getTransportTypeFromNC()
98 boolean hasVpn = nc.hasTransport(TRANSPORT_VPN); in getTransportTypeFromNC()
99 boolean hasWifiAware = nc.hasTransport(TRANSPORT_WIFI_AWARE); in getTransportTypeFromNC()
100 boolean hasLopan = nc.hasTransport(TRANSPORT_LOWPAN); in getTransportTypeFromNC()
/packages/modules/NetworkStack/common/moduleutils/src/android/net/shared/
DNetworkMonitorUtils.java91 if (nc.hasTransport(TRANSPORT_TEST) && nc.hasCapability(NET_CAPABILITY_NOT_RESTRICTED) && ( in isPrivateDnsValidationRequired()
92 nc.hasTransport(TRANSPORT_WIFI) in isPrivateDnsValidationRequired()
93 || nc.hasTransport(TRANSPORT_CELLULAR) in isPrivateDnsValidationRequired()
94 || nc.hasTransport(TRANSPORT_BLUETOOTH) in isPrivateDnsValidationRequired()
95 || nc.hasTransport(TRANSPORT_ETHERNET))) { in isPrivateDnsValidationRequired()
/packages/modules/Connectivity/tests/common/java/android/net/
DNetworkCapabilitiesTest.java994 assertFalse(nc.hasTransport(i)); in assertNoTransport()
1005 assertTrue(nc.hasTransport(i)); in checkCurrentTransportTypes()
1007 assertFalse(nc.hasTransport(i)); in checkCurrentTransportTypes()
1012 assertFalse(nc.hasTransport(i)); in checkCurrentTransportTypes()
1014 assertTrue(nc.hasTransport(i)); in checkCurrentTransportTypes()
1035 assertTrue(nc.hasTransport(TRANSPORT_WIFI)); in testMultipleTransportTypes()
1036 assertFalse(nc.hasTransport(TRANSPORT_VPN)); in testMultipleTransportTypes()
1038 assertTrue(nc.hasTransport(TRANSPORT_WIFI)); in testMultipleTransportTypes()
1039 assertTrue(nc.hasTransport(TRANSPORT_VPN)); in testMultipleTransportTypes()
1041 assertFalse(nc.hasTransport(TRANSPORT_WIFI)); in testMultipleTransportTypes()
[all …]
DNetworkProviderTest.kt151 callback.request.hasTransport(TRANSPORT_TEST) in <lambda>()
188 callback.request.hasTransport(TRANSPORT_TEST) in <lambda>()
/packages/modules/Connectivity/service/src/com/android/server/connectivity/
DLingerMonitor.java115 private static boolean hasTransport(NetworkAgentInfo nai, int transport) { in hasTransport() method in LingerMonitor
116 return nai.networkCapabilities.hasTransport(transport); in hasTransport()
150 if (hasTransport(fromNai, fromTransport) && hasTransport(toNai, toTransport)) { in isNotificationEnabled()
DFullScore.java163 caps.hasTransport(TRANSPORT_VPN), in fromNetworkScore()
190 final boolean vpn = caps.hasTransport(TRANSPORT_VPN); in makeProspectiveScore()
226 caps.hasTransport(TRANSPORT_VPN), in mixInScore()
DNetworkRanker.java113 && candidate.getCapsNoCopy().hasTransport(TRANSPORT_WIFI); in isBadWiFi()
263 partitionInto(candidates, nai -> nai.getCapsNoCopy().hasTransport(transport), in getBestNetworkByPolicy()
DNetworkAgentInfo.java733 return networkCapabilities.hasTransport(TRANSPORT_CELLULAR) && !mConnService.avoidBadWifi(); in yieldToBadWiFi()
898 return networkCapabilities.hasTransport(NetworkCapabilities.TRANSPORT_VPN); in isVPN()
/packages/apps/Car/Settings/tests/robotests/src/com/android/car/settings/datausage/
DDataUsageEntryPreferenceControllerTest.java84 when(mNetworkCapabilities.hasTransport(NetworkCapabilities.TRANSPORT_CELLULAR)).thenReturn( in setUp()
98 when(mNetworkCapabilities.hasTransport(NetworkCapabilities.TRANSPORT_CELLULAR)).thenReturn( in getAvailabilityStatus_noMobileNetwork_isUnsupported()
106 when(mNetworkCapabilities.hasTransport(NetworkCapabilities.TRANSPORT_CELLULAR)).thenReturn( in getAvailabilityStatus_hasMobileNetwork_isAvailable()
/packages/modules/NetworkStack/tests/unit/src/android/net/testutils/
DTestableNetworkCallbackTest.kt145 cb is CapabilitiesChanged && cb.caps.hasTransport(WIFI) in <lambda>()
166 caps.hasTransport(WIFI) && in <lambda>()
167 !caps.hasTransport(CELLULAR) in <lambda>()
171 caps.hasTransport(CELLULAR) in <lambda>()
/packages/modules/Connectivity/tests/cts/hostside/app/src/com/android/cts/net/hostside/
DNetworkPolicyTestUtils.java170 return networkCapabilities.hasTransport(TRANSPORT_WIFI) in canChangeActiveNetworkMeteredness()
171 || networkCapabilities.hasTransport(TRANSPORT_CELLULAR); in canChangeActiveNetworkMeteredness()
187 if (networkCapabilities.hasTransport(TRANSPORT_WIFI)) { in setupActiveNetworkMeteredness()
191 } else if (networkCapabilities.hasTransport(TRANSPORT_CELLULAR)) { in setupActiveNetworkMeteredness()
DVpnTest.java829 assertFalse(nc.hasTransport(TRANSPORT_VPN)); in testAppDisallowed()
1144 assertTrue(vpnCaps.hasTransport(transport)); in assertVpnTransportContains()
1151 assertTrue(vpnNc.hasTransport(TRANSPORT_VPN)); in maybeExpectVpnTransportInfo()
/packages/modules/Connectivity/tests/unit/java/com/android/server/
DConnectivityServiceTest.java1916 assertTrue(mCm.getNetworkCapabilities(mCm.getActiveNetwork()).hasTransport(transport)); in verifyActiveNetwork()
6130 assertTrue(capabilities.hasTransport(TRANSPORT_WIFI_AWARE)); in testNetworkInfoOfTypeNone()
6479 assertFalse(nc.hasTransport(TRANSPORT_WIFI)); in testNonVpnUnderlyingNetworks()
6503 assertFalse(nc.hasTransport(TRANSPORT_WIFI)); in testNonVpnUnderlyingNetworks()
6995 .hasTransport(TRANSPORT_VPN)); in testVpnConnectDisconnectUnderlyingNetwork()
6997 .hasTransport(TRANSPORT_WIFI)); in testVpnConnectDisconnectUnderlyingNetwork()
7016 .hasTransport(TRANSPORT_VPN)); in testVpnConnectDisconnectUnderlyingNetwork()
7018 .hasTransport(TRANSPORT_WIFI)); in testVpnConnectDisconnectUnderlyingNetwork()
7024 nc.getTransportTypes().length == 1 && nc.hasTransport(TRANSPORT_VPN)); in testVpnConnectDisconnectUnderlyingNetwork()
7051 && nc.hasTransport(TRANSPORT_CELLULAR)); in testVpnUnderlyingNetworkSuspended()
[all …]
/packages/apps/Car/Settings/tests/robotests/src/com/android/car/settings/network/
DNetworkUtilsTest.java44 when(capabilities.hasTransport(NetworkCapabilities.TRANSPORT_CELLULAR)).thenReturn(true); in hasMobileNetwork_hasCellularCapabilities_returnsTrue()
57 when(capabilities.hasTransport(NetworkCapabilities.TRANSPORT_CELLULAR)).thenReturn(false); in hasMobileNetwork_hasNoCellularCapabilities_returnsFalse()
/packages/modules/Connectivity/framework/src/android/net/
DNetworkRequest.java439 } else if (mNetworkCapabilities.hasTransport(TRANSPORT_TEST)) { in setNetworkSpecifier()
659 public boolean hasTransport(@Transport int transportType) { in hasTransport() method in NetworkRequest
660 return networkCapabilities.hasTransport(transportType); in hasTransport()
/packages/modules/Connectivity/tests/cts/tethering/src/android/tethering/cts/
DTetheringManagerTest.java444 assumeFalse(activeNetCap.hasTransport(TRANSPORT_ETHERNET)); in testTetheringUpstream()
446 assertTrue(activeNetCap.hasTransport(TRANSPORT_CELLULAR)); in testTetheringUpstream()
456 assertTrue(netCap.hasTransport(TRANSPORT_CELLULAR)); in testTetheringUpstream()
/packages/services/Iwlan/src/com/google/android/iwlan/
DIwlanNetworkService.java115 if (networkCapabilities.hasTransport(TRANSPORT_CELLULAR)) { in onCapabilitiesChanged()
118 } else if (networkCapabilities.hasTransport(TRANSPORT_WIFI)) { in onCapabilitiesChanged()
/packages/apps/Car/Settings/tests/unit/src/com/android/car/settings/network/
DMobileNetworkEntryPreferenceControllerTest.java107 when(mNetworkCapabilities.hasTransport(NetworkCapabilities.TRANSPORT_CELLULAR)).thenReturn( in setUp()
124 when(mNetworkCapabilities.hasTransport(NetworkCapabilities.TRANSPORT_CELLULAR)).thenReturn( in getAvailabilityStatus_noMobileNetwork_unsupported()
/packages/modules/IPsec/src/java/com/android/internal/net/ipsec/ike/utils/
DRandomnessFactory.java44 networkCapabilities != null && networkCapabilities.hasTransport(TRANSPORT_TEST); in RandomnessFactory()
/packages/apps/Car/Settings/src/com/android/car/settings/network/
DNetworkUtils.java40 if (capabilities.hasTransport(NetworkCapabilities.TRANSPORT_CELLULAR)) { in hasMobileNetwork()
/packages/modules/Connectivity/Tethering/src/com/android/networkstack/tethering/
DTetheringInterfaceUtils.java81 && ns.networkCapabilities.hasTransport(NetworkCapabilities.TRANSPORT_CELLULAR); in getIPv6Interface()
/packages/modules/Wifi/service/tests/wifitests/src/com/android/server/wifi/
DWifiShellCommandTest.java583 return (nR.hasTransport(TRANSPORT_WIFI)) in testAddSuggestionWithUntrusted()
618 return (nR.hasTransport(TRANSPORT_WIFI)) in testAddSuggestionWithOemPaid()
653 return (nR.hasTransport(TRANSPORT_WIFI)) in testAddSuggestionWithOemPrivate()
/packages/modules/Connectivity/tests/cts/net/src/android/net/cts/
DConnectivityDiagnosticsManagerTest.java513 assertTrue(nc.hasTransport(transportType)); in maybeVerifyOnConnectivityReportAvailable()
553 assertTrue(nc.hasTransport(TRANSPORT_TEST)); in expectOnDataStallSuspected()
DNetworkRequestTest.java128 .hasTransport(TRANSPORT_BLUETOOTH)); in testTransports()
130 .hasTransport(TRANSPORT_BLUETOOTH)); in testTransports()
/packages/apps/Settings/src/com/android/settings/development/
DWirelessDebuggingPreferenceController.java153 if (nc.hasTransport(NetworkCapabilities.TRANSPORT_WIFI)) { in isWifiConnected()

123