Home
last modified time | relevance | path

Searched refs:ForwardedStats (Results 1 – 7 of 7) sorted by relevance

/packages/modules/Connectivity/Tethering/src/android/net/util/
DTetheringUtils.java66 public static class ForwardedStats { class in TetheringUtils
72 public ForwardedStats() { in ForwardedStats() method in TetheringUtils.ForwardedStats
79 public ForwardedStats(long rxBytes, long txBytes) { in ForwardedStats() method in TetheringUtils.ForwardedStats
86 public ForwardedStats(long rxBytes, long rxPackets, long txBytes, long txPackets) { in ForwardedStats() method in TetheringUtils.ForwardedStats
93 public ForwardedStats(@NonNull TetherStatsParcel tetherStats) { in ForwardedStats() method in TetheringUtils.ForwardedStats
100 public ForwardedStats(@NonNull TetherStatsValue tetherStats) { in ForwardedStats() method in TetheringUtils.ForwardedStats
107 public ForwardedStats(@NonNull ForwardedStats other) { in ForwardedStats() method in TetheringUtils.ForwardedStats
116 public ForwardedStats add(@NonNull ForwardedStats other) { in add()
117 return new ForwardedStats(rxBytes + other.rxBytes, rxPackets + other.rxPackets, in add()
123 public ForwardedStats subtract(@NonNull ForwardedStats other) { in subtract()
[all …]
/packages/modules/Connectivity/Tethering/src/com/android/networkstack/tethering/
DOffloadController.java59 import com.android.networkstack.tethering.OffloadHardwareInterface.ForwardedStats;
84 private static final ForwardedStats EMPTY_STATS = new ForwardedStats();
116 private ConcurrentHashMap<String, ForwardedStats> mForwardedStats =
359 for (final Map.Entry<String, ForwardedStats> kv : mForwardedStats.entrySet()) { in getTetherStats()
360 final ForwardedStats value = kv.getValue(); in getTetherStats()
464 ForwardedStats diff = mHwInterface.getForwardedStats(iface); in maybeUpdateStats()
466 ForwardedStats base = mForwardedStats.get(iface); in maybeUpdateStats()
560 for (Map.Entry<String, ForwardedStats> kv : mForwardedStats.entrySet()) { in updateStatsForAllUpstreams()
DOffloadHardwareInterface.java154 public static class ForwardedStats { class in OffloadHardwareInterface
158 public ForwardedStats() { in ForwardedStats() method in OffloadHardwareInterface.ForwardedStats
164 public ForwardedStats(long rxBytes, long txBytes) { in ForwardedStats() method in OffloadHardwareInterface.ForwardedStats
170 public void add(ForwardedStats other) { in add()
425 public ForwardedStats getForwardedStats(String upstream) { in getForwardedStats()
428 final ForwardedStats stats = new ForwardedStats(); in getForwardedStats()
DBpfCoordinator.java51 import android.net.util.TetheringUtils.ForwardedStats;
179 private final SparseArray<ForwardedStats> mStats = new SparseArray<>();
990 final ForwardedStats stats = mStats.get(upstreamIfindex); in dumpStats()
1775 @NonNull final ForwardedStats diff) { in buildNetworkStats()
1811 final ForwardedStats curr = new ForwardedStats(tetherStats); in updateQuotaAndStatsFromSnapshot()
1812 final ForwardedStats base = mStats.get(ifIndex); in updateQuotaAndStatsFromSnapshot()
1813 final ForwardedStats diff = (base != null) ? curr.subtract(base) : curr; in updateQuotaAndStatsFromSnapshot()
/packages/modules/Connectivity/Tethering/tests/unit/src/com/android/networkstack/tethering/
DOffloadControllerTest.java31 import static com.android.networkstack.tethering.OffloadHardwareInterface.ForwardedStats;
150 when(mHardware.getForwardedStats(any())).thenReturn(new ForwardedStats()); in setupFunctioningHardwareInterface()
426 new ForwardedStats(12345, 54321)); in testGetForwardedStats()
428 new ForwardedStats(999, 99999)); in testGetForwardedStats()
467 new ForwardedStats(100000, 100000)); in testGetForwardedStats()
865 new ForwardedStats(0, 0)); in testOnSetAlert()
873 new ForwardedStats(50, 50)); in testOnSetAlert()
DOffloadHardwareInterfaceTest.java148 final OffloadHardwareInterface.ForwardedStats stats = mOffloadHw.getForwardedStats(RMNET0); in testGetForwardedStats()
DTetheringTest.java245 @Mock private OffloadHardwareInterface.ForwardedStats mForwardedStats;