Home
last modified time | relevance | path

Searched refs:totalWakeLockData (Results 1 – 4 of 4) sorted by relevance

/frameworks/base/core/java/android/os/
DWakeLockStats.java104 @NonNull public final WakeLockData totalWakeLockData; field in WakeLockStats.WakeLock
113 @NonNull WakeLockData totalWakeLockData, in WakeLock() argument
118 this.totalWakeLockData = totalWakeLockData; in WakeLock()
124 WakeLockData totalWakeLockData, WakeLockData backgroundWakeLockData) { in isDataValid() argument
125 return totalWakeLockData.totalTimeHeldMs > 0 in isDataValid()
126 && totalWakeLockData.isDataValid() in isDataValid()
128 && totalWakeLockData.timesAcquired >= backgroundWakeLockData.timesAcquired in isDataValid()
129 && totalWakeLockData.totalTimeHeldMs >= backgroundWakeLockData.totalTimeHeldMs in isDataValid()
130 && totalWakeLockData.timeHeldMs >= backgroundWakeLockData.timeHeldMs; in isDataValid()
137 totalWakeLockData = new WakeLockData(in); in WakeLock()
[all …]
/frameworks/base/core/tests/coretests/src/android/os/
DWakeLockStatsTest.java79 final WakeLockStats.WakeLockData totalWakeLockData = in isDataValidOfWakeLock_invalidData_returnFalse() local
86 assertThat(WakeLockStats.WakeLock.isDataValid(totalWakeLockData, backgroundWakeLockData)) in isDataValidOfWakeLock_invalidData_returnFalse()
92 final WakeLockStats.WakeLockData totalWakeLockData = in isDataValidOfWakeLock_totalSmallerThanBackground_returnFalse() local
99 assertThat(WakeLockStats.WakeLock.isDataValid(totalWakeLockData, backgroundWakeLockData)) in isDataValidOfWakeLock_totalSmallerThanBackground_returnFalse()
105 final WakeLockStats.WakeLockData totalWakeLockData = in isDataValidOfWakeLock_returnTrue() local
112 assertThat(WakeLockStats.WakeLock.isDataValid(totalWakeLockData, backgroundWakeLockData)) in isDataValidOfWakeLock_returnTrue()
156 assertThat(actualWakelock.totalWakeLockData.timesAcquired).isEqualTo(10); in parcelablity()
157 assertThat(actualWakelock.totalWakeLockData.totalTimeHeldMs).isEqualTo(60); in parcelablity()
158 assertThat(actualWakelock.totalWakeLockData.timeHeldMs).isEqualTo(50); in parcelablity()
168 assertThat(actualAggregatedWakelock.totalWakeLockData.timesAcquired).isEqualTo(20); in parcelablity()
[all …]
/frameworks/base/services/tests/powerstatstests/src/com/android/server/power/stats/
DBatteryStatsImplTest.java635 assertThat(wakeLock1.totalWakeLockData.timesAcquired).isEqualTo(1); in testGetWakeLockStats()
636 assertThat(wakeLock1.totalWakeLockData.timeHeldMs).isEqualTo(0); // Not currently held in testGetWakeLockStats()
637 assertThat(wakeLock1.totalWakeLockData.totalTimeHeldMs).isEqualTo(2000); // 3000-1000 in testGetWakeLockStats()
641 assertThat(wakeLock3.totalWakeLockData.timesAcquired).isEqualTo(1); in testGetWakeLockStats()
642 assertThat(wakeLock3.totalWakeLockData.timeHeldMs).isEqualTo(0); // Not currently held in testGetWakeLockStats()
644 assertThat(wakeLock3.totalWakeLockData.totalTimeHeldMs).isEqualTo(2166); in testGetWakeLockStats()
648 assertThat(wakeLock4.totalWakeLockData.timesAcquired).isEqualTo(1); in testGetWakeLockStats()
649 assertThat(wakeLock4.totalWakeLockData.timeHeldMs).isEqualTo(0); // Not currently held in testGetWakeLockStats()
650 assertThat(wakeLock4.totalWakeLockData.totalTimeHeldMs).isEqualTo(333); // (9000-8000)/3 in testGetWakeLockStats()
654 assertThat(wakeLock5.totalWakeLockData.timesAcquired).isEqualTo(1); in testGetWakeLockStats()
[all …]
/frameworks/base/services/core/java/com/android/server/power/stats/
DBatteryStatsImpl.java1731 final WakeLockStats.WakeLockData totalWakeLockData = createWakeLockData(timer, realtimeMs); in createWakeLock() local
1735 return WakeLockStats.WakeLock.isDataValid(totalWakeLockData, backgroundWakeLockData) in createWakeLock()
1740 totalWakeLockData, in createWakeLock()