/aosp12/packages/modules/Connectivity/tests/unit/java/com/android/server/connectivity/ |
H A D | LingerMonitorTest.java | 119 NetworkAgentInfo to = cellNai(101); in testNotificationOnLinger() 130 NetworkAgentInfo to = cellNai(101); in testToastOnLinger() 141 NetworkAgentInfo to = cellNai(101); in testNotificationClearedAfterDisconnect() 155 NetworkAgentInfo to = cellNai(101); in testNotificationClearedAfterSwitchingBack() 169 NetworkAgentInfo to = cellNai(101); in testUniqueToast() 259 NetworkAgentInfo to = cellNai(101); in testUniqueNotification() 355 void verifyToast(NetworkAgentInfo from, NetworkAgentInfo to) { in verifyToast() 360 void verifyNotification(NetworkAgentInfo from, NetworkAgentInfo to) { in verifyNotification() 371 NetworkAgentInfo nai = new NetworkAgentInfo(null, new Network(netId), info, in nai() 380 NetworkAgentInfo wifiNai(int netId) { in wifiNai() [all …]
|
H A D | IpConnectivityMetricsTest.java | 138 private void logDefaultNetworkEvent(long timeMs, NetworkAgentInfo nai, in logDefaultNetworkEvent() 139 NetworkAgentInfo oldNai) { in logDefaultNetworkEvent() 159 NetworkAgentInfo[][] defaultNetworks = { in testDefaultNetworkEvents() 174 for (NetworkAgentInfo[] pair : defaultNetworks) { in testDefaultNetworkEvents() 351 NetworkAgentInfo cellNai = makeNai(100, 50, false, true, cell); in testEndToEndLogging() 352 NetworkAgentInfo wifiNai = makeNai(101, 60, true, false, wifi); in testEndToEndLogging() 614 NetworkAgentInfo makeNai(int netId, int score, boolean ipv4, boolean ipv6, long transports) { in makeNai() 615 NetworkAgentInfo nai = mock(NetworkAgentInfo.class); in makeNai()
|
H A D | NetworkNotificationManagerTest.java | 145 @Mock NetworkAgentInfo mWifiNai; 146 @Mock NetworkAgentInfo mCellNai; 147 @Mock NetworkAgentInfo mVpnNai; 195 private void verifyTitleByNetwork(final int id, final NetworkAgentInfo nai, final int title) { in verifyTitleByNetwork()
|
H A D | Nat464XlatTest.java | 77 @Mock NetworkAgentInfo mNai; 125 private void assertRequiresClat(boolean expected, NetworkAgentInfo nai) { 135 private void assertShouldStartClat(boolean expected, NetworkAgentInfo nai) {
|
/aosp12/packages/modules/Connectivity/service/src/com/android/server/connectivity/ |
H A D | LingerMonitor.java | 115 private static boolean hasTransport(NetworkAgentInfo nai, int transport) { in hasTransport() 119 private int getNotificationSource(NetworkAgentInfo toNai) { in getNotificationSource() 128 private boolean everNotified(NetworkAgentInfo nai) { in everNotified() 133 public boolean isNotificationEnabled(NetworkAgentInfo fromNai, NetworkAgentInfo toNai) { in isNotificationEnabled() 158 private void showNotification(NetworkAgentInfo fromNai, NetworkAgentInfo toNai) { in showNotification() 173 private void maybeStopNotifying(NetworkAgentInfo nai) { in maybeStopNotifying() 183 private void notify(NetworkAgentInfo fromNai, NetworkAgentInfo toNai, boolean forceToast) { in notify() 228 public void noteLingerDefaultNetwork(@NonNull final NetworkAgentInfo fromNai, in noteLingerDefaultNetwork() 229 @Nullable final NetworkAgentInfo toNai) { in noteLingerDefaultNetwork() 299 public void noteDisconnect(NetworkAgentInfo nai) { in noteDisconnect()
|
H A D | KeepaliveTracker.java | 136 private final NetworkAgentInfo mNai; 160 @NonNull NetworkAgentInfo nai, in KeepaliveInfo() 206 public NetworkAgentInfo getNai() { in getNai() 429 private int findFirstFreeSlot(NetworkAgentInfo nai) { in findFirstFreeSlot() 449 NetworkAgentInfo nai = ki.getNai(); in handleStartKeepalive() 469 final String networkName = NetworkAgentInfo.toShortString(nai); in handleStopKeepalive() 486 final String networkName = NetworkAgentInfo.toShortString(nai); in cleanupStoppedKeepalive() 607 public void startNattKeepalive(@Nullable NetworkAgentInfo nai, in startNattKeepalive() 661 public void startTcpKeepalive(@Nullable NetworkAgentInfo nai, in startTcpKeepalive() 700 public void startNattKeepalive(@Nullable NetworkAgentInfo nai, in startNattKeepalive() [all …]
|
H A D | NetworkRanker.java | 74 public NetworkAgentInfo getBestNetwork(@NonNull final NetworkRequest request, in getBestNetwork() 75 @NonNull final Collection<NetworkAgentInfo> nais, in getBestNetwork() 76 @Nullable final NetworkAgentInfo currentSatisfier) { in getBestNetwork() 77 final ArrayList<NetworkAgentInfo> candidates = filter(nais, nai -> nai.satisfies(request)); in getBestNetwork() 284 private NetworkAgentInfo getBestNetworkByLegacyInt( in getBestNetworkByLegacyInt() 285 @NonNull final Collection<NetworkAgentInfo> nais) { in getBestNetworkByLegacyInt() 286 NetworkAgentInfo bestNetwork = null; in getBestNetworkByLegacyInt() 288 for (final NetworkAgentInfo nai : nais) { in getBestNetworkByLegacyInt() 317 @Nullable final NetworkAgentInfo champion, in mightBeat()
|
H A D | NetworkAgentInfo.java | 147 public class NetworkAgentInfo implements Comparable<NetworkAgentInfo>, NetworkRanker.Scoreable { class 351 public NetworkAgentInfo(INetworkAgent na, Network net, NetworkInfo info, in NetworkAgentInfo() method in NetworkAgentInfo 624 new Pair<>(NetworkAgentInfo.this, nc)).sendToTarget(); in sendNetworkCapabilities() 631 new Pair<>(NetworkAgentInfo.this, lp)).sendToTarget(); in sendLinkProperties() 638 new Pair<>(NetworkAgentInfo.this, info)).sendToTarget(); in sendNetworkInfo() 644 new Pair<>(NetworkAgentInfo.this, score)).sendToTarget(); in sendScore() 651 new Pair<>(NetworkAgentInfo.this, null)).sendToTarget(); in sendExplicitlySelected() 663 new Pair<>(NetworkAgentInfo.this, networks)).sendToTarget(); in sendUnderlyingNetworks() 698 new Pair<>(NetworkAgentInfo.this, durationMs)).sendToTarget(); in sendLingerDuration() 1207 public int compareTo(NetworkAgentInfo other) { [all …]
|
H A D | NetworkNotificationManager.java | 106 protected static int approximateTransportType(NetworkAgentInfo nai) { in approximateTransportType() 111 private static int getFirstTransportType(NetworkAgentInfo nai) { in getFirstTransportType() 157 public void showNotification(int id, NotificationType notifyType, NetworkAgentInfo nai, in showNotification() 158 NetworkAgentInfo switchToNai, PendingIntent intent, boolean highPriority) { in showNotification() 389 public void showToast(NetworkAgentInfo fromNai, NetworkAgentInfo toNai) { in showToast()
|
H A D | QosCallbackTracker.java | 93 @NonNull final QosFilter filter, @NonNull final NetworkAgentInfo networkAgentInfo) { in registerCallback() 105 @NonNull final NetworkAgentInfo networkAgentInfo) { in handleRegisterCallback() 119 @NonNull final NetworkAgentInfo networkAgentInfo) { in handleRegisterCallbackInternal()
|
H A D | Nat464Xlat.java | 76 private final NetworkAgentInfo mNetwork; 103 public Nat464Xlat(NetworkAgentInfo nai, INetd netd, IDnsResolver dnsResolver, in Nat464Xlat() 120 protected boolean requiresClat(NetworkAgentInfo nai) { in requiresClat() 148 protected boolean shouldStartClat(NetworkAgentInfo nai) { in shouldStartClat()
|
H A D | QosCallbackAgentConnection.java | 52 @NonNull private final NetworkAgentInfo mNetworkAgentInfo; 97 @NonNull final NetworkAgentInfo networkAgentInfo) { in QosCallbackAgentConnection()
|
/aosp12/packages/modules/Connectivity/service/src/com/android/server/ |
H A D | ConnectivityService.java | 3215 NetworkAgentInfo[] networks = new NetworkAgentInfo[0]; in networksSortedById() 3254 final Pair<NetworkAgentInfo, Object> arg = (Pair<NetworkAgentInfo, Object>) msg.obj; in maybeHandleNetworkAgentMessage() 3533 NetworkAgentInfo nai = (NetworkAgentInfo) msg.obj; in maybeHandleNetworkAgentInfoMessage() 3818 final NetworkAgentInfo nai = (NetworkAgentInfo) msg.obj; in handleNetworkAgentRegistered() 3841 NetworkAgentInfo nai = (NetworkAgentInfo) msg.obj; in handleNetworkAgentDisconnected() 5094 final NetworkAgentInfo nai; in reportNetworkConnectivity() 5113 final NetworkAgentInfo nai; in handleReportNetworkConnectivity() 5696 NetworkAgentInfo getSatisfier() { in getSatisfier() 6192 NetworkAgentInfo nai = null; in requestBandwidthUpdate() 6766 final NetworkAgentInfo nai = new NetworkAgentInfo(na, in registerNetworkAgentInternal() [all …]
|
/aosp12/packages/modules/Connectivity/tests/unit/java/com/android/server/ |
H A D | LegacyTypeTrackerTest.kt | 50 import com.android.server.connectivity.NetworkAgentInfo 138 val mobileNai = mock(NetworkAgentInfo::class.java) 159 val mobileNai = mock(NetworkAgentInfo::class.java) 160 val wifiNai = mock(NetworkAgentInfo::class.java) 166 val secondMobileNai = mock(NetworkAgentInfo::class.java) 187 val mobileNai1 = mock(NetworkAgentInfo::class.java) 188 val mobileNai2 = mock(NetworkAgentInfo::class.java)
|
H A D | ConnectivityServiceTest.java | 325 import com.android.server.connectivity.NetworkAgentInfo; 10259 public NetworkAgentInfo fakeMobileNai(NetworkCapabilities nc) { in fakeMobileNai() 10268 private NetworkAgentInfo fakeWifiNai(NetworkCapabilities nc) { in fakeWifiNai() 10276 private NetworkAgentInfo fakeNai(NetworkCapabilities nc, NetworkInfo networkInfo) { in fakeNai() 10302 final NetworkAgentInfo naiWithUid = fakeWifiNai(nc); in testCheckConnectivityDiagnosticsPermissionsWrongUidPackageName() 10313 NetworkAgentInfo info, boolean expectPermission) { in verifyConnectivityDiagnosticsPermissionsWithNetworkAgentInfo() 10328 final NetworkAgentInfo naiWithUid = fakeMobileNai(nc); in testCheckConnectivityDiagnosticsPermissionsCellularNoLocationPermission() 10339 final NetworkAgentInfo naiWithUid = fakeWifiNai(nc); in testCheckConnectivityDiagnosticsPermissionsWifiNoLocationPermission() 10378 final NetworkAgentInfo naiWithUid = fakeMobileNai(nc); in testCheckConnectivityDiagnosticsPermissionsNetworkAdministrator() 10395 final NetworkAgentInfo naiWithUid = fakeMobileNai(nc); in testCheckConnectivityDiagnosticsPermissionsFails() [all …]
|
/aosp12/packages/modules/Connectivity/services/core/java/com/android/server/ |
H A D | ConnectivityService.java | 139 import com.android.server.connectivity.NetworkAgentInfo; 589 public void remove(NetworkAgentInfo nai) { in remove() 3110 NetworkAgentInfo nai = (NetworkAgentInfo)msg.obj; in handleMessage() 3115 NetworkAgentInfo nai = (NetworkAgentInfo)msg.obj; in handleMessage() 3266 final ArrayList<NetworkAgentInfo> toActivate = new ArrayList<NetworkAgentInfo>(); in handleAsyncChannelDisconnected() 3279 NetworkAgentInfo existing = (NetworkAgentInfo)entry.getValue(); in handleAsyncChannelDisconnected() 3309 NetworkAgentInfo bestNetwork = null; in handleRegisterNetworkRequest() 5506 new SparseArray<NetworkAgentInfo>(); 5509 new SparseArray<NetworkAgentInfo>(); 5523 NetworkAgentInfo nai = new NetworkAgentInfo(messenger, new AsyncChannel(), nextNetId(), in registerNetworkAgent() [all …]
|
/aosp12/packages/modules/Connectivity/services/core/java/com/android/server/connectivity/ |
H A D | NetworkAgentInfo.java | 40 public class NetworkAgentInfo { class 55 public NetworkAgentInfo(Messenger messenger, AsyncChannel ac, int netId, NetworkInfo info, in NetworkAgentInfo() method in NetworkAgentInfo
|
H A D | Nat464Xlat.java | 92 public boolean requiresClat(NetworkAgentInfo network) { in requiresClat() 109 public void startClat(NetworkAgentInfo network) { in startClat()
|