Home
last modified time | relevance | path

Searched refs:MIN_NET_ID (Results 1 – 2 of 2) sorted by relevance

/frameworks/base/tests/net/java/com/android/server/
DNetIdManagerTest.kt21 import com.android.server.NetIdManager.MIN_NET_ID
33 val manager = NetIdManager(MIN_NET_ID + 4) in testReserveReleaseNetId()
34 assertEquals(MIN_NET_ID, manager.reserveNetId()) in testReserveReleaseNetId()
35 assertEquals(MIN_NET_ID + 1, manager.reserveNetId()) in testReserveReleaseNetId()
36 assertEquals(MIN_NET_ID + 2, manager.reserveNetId()) in testReserveReleaseNetId()
37 assertEquals(MIN_NET_ID + 3, manager.reserveNetId()) in testReserveReleaseNetId()
39 manager.releaseNetId(MIN_NET_ID + 1) in testReserveReleaseNetId()
40 manager.releaseNetId(MIN_NET_ID + 3) in testReserveReleaseNetId()
42 assertEquals(MIN_NET_ID + 4, manager.reserveNetId()) in testReserveReleaseNetId()
43 assertEquals(MIN_NET_ID + 1, manager.reserveNetId()) in testReserveReleaseNetId()
[all …]
/frameworks/base/services/core/java/com/android/server/
DNetIdManager.java32 public static final int MIN_NET_ID = 100; // some reserved marks field in NetIdManager
40 private int mLastNetId = MIN_NET_ID - 1;
59 for (int i = MIN_NET_ID; i <= mMaxNetId; i++) { in getNextAvailableNetIdLocked()
60 netId = netId < mMaxNetId ? netId + 1 : MIN_NET_ID; in getNextAvailableNetIdLocked()