/frameworks/opt/net/wifi/tests/wifitests/src/com/android/server/wifi/ |
D | WifiLockManagerTest.java | 53 @Mock IBatteryStats mBatteryStats; field in WifiLockManagerTest 66 mWifiLockManager = new WifiLockManager(mContext, mBatteryStats); in setUp() 77 InOrder inOrder = inOrder(binder, mBatteryStats); in acquireWifiLockSuccessful() 79 inOrder.verify(mBatteryStats).noteFullWifiLockAcquiredFromSource(ws); in acquireWifiLockSuccessful() 87 InOrder inOrder = inOrder(binder, mBatteryStats); in releaseWifiLockSuccessful() 89 inOrder.verify(mBatteryStats).noteFullWifiLockReleasedFromSource(any(WorkSource.class)); in releaseWifiLockSuccessful() 241 InOrder inOrder = inOrder(mBatteryStats); in testUpdateWifiLockWorkSourceCalledWithWorkSource() 242 inOrder.verify(mBatteryStats).noteFullWifiLockReleasedFromSource(mWorkSource); in testUpdateWifiLockWorkSourceCalledWithWorkSource() 243 inOrder.verify(mBatteryStats).noteFullWifiLockAcquiredFromSource(eq(newWorkSource)); in testUpdateWifiLockWorkSourceCalledWithWorkSource() 260 InOrder inOrder = inOrder(mBatteryStats); in testUpdateWifiLockWorkSourceCalledWithUID() [all …]
|
D | WifiMulticastLockManagerTest.java | 41 @Mock IBatteryStats mBatteryStats; field in WifiMulticastLockManagerTest 50 mManager = new WifiMulticastLockManager(mHandler, mBatteryStats); in setUp() 74 verify(mBatteryStats).noteWifiMulticastEnabled(anyInt()); in oneLock() 75 verify(mBatteryStats, times(0)).noteWifiMulticastDisabled(anyInt()); in oneLock() 78 verify(mBatteryStats).noteWifiMulticastDisabled(anyInt()); in oneLock()
|
D | WifiStateTrackerTest.java | 40 @Mock IBatteryStats mBatteryStats; field in WifiStateTrackerTest 49 mWifiStateTracker = new WifiStateTracker(mBatteryStats); in setUp() 64 verify(mBatteryStats, times(relevantStates.length)).noteWifiState(anyInt(), any()); in testBatteryStatsUpdated() 78 verify(mBatteryStats, times(0)).noteWifiState(anyInt(), any()); in testBatteryStatsNotUpdated()
|
/frameworks/base/packages/SettingsLib/tests/robotests/src/com/android/settingslib/ |
D | BatteryInfoTest.java | 55 private BatteryStats mBatteryStats; field in BatteryInfoTest 88 doReturn(REMAINING_TIME_NULL).when(mBatteryStats).computeBatteryTimeRemaining(anyLong()); in testGetBatteryInfo_hasStatusLabel() 90 mBatteryStats, SystemClock.elapsedRealtime() * 1000, true); in testGetBatteryInfo_hasStatusLabel() 97 doReturn(REMAINING_TIME).when(mBatteryStats).computeChargeTimeRemaining(anyLong()); in testGetBatteryInfo_doNotShowChargingMethod_hasRemainingTime() 99 mBatteryStats, SystemClock.elapsedRealtime() * 1000, false); in testGetBatteryInfo_doNotShowChargingMethod_hasRemainingTime() 106 doReturn(REMAINING_TIME_NULL).when(mBatteryStats).computeChargeTimeRemaining(anyLong()); in testGetBatteryInfo_doNotShowChargingMethod_noRemainingTime() 108 mBatteryStats, SystemClock.elapsedRealtime() * 1000, false); in testGetBatteryInfo_doNotShowChargingMethod_noRemainingTime() 116 mBatteryStats, SystemClock.elapsedRealtime() * 1000, true); in testGetBatteryInfo_pluggedIn_dischargingFalse()
|
/frameworks/base/core/java/android/os/health/ |
D | SystemHealthManager.java | 46 private final IBatteryStats mBatteryStats; field in SystemHealthManager 58 mBatteryStats = batteryStats; in SystemHealthManager() 87 final HealthStatsParceler parceler = mBatteryStats.takeUidSnapshot(uid); in takeUidSnapshot() 122 final HealthStatsParceler[] parcelers = mBatteryStats.takeUidSnapshots(uids); in takeUidSnapshots()
|
/frameworks/base/services/core/java/com/android/server/power/ |
D | Notifier.java | 90 private final IBatteryStats mBatteryStats; field in Notifier 136 mBatteryStats = batteryStats; in Notifier() 164 mBatteryStats.noteInteractive(true); in Notifier() 186 mBatteryStats.noteStartWakelockFromSource(workSource, ownerPid, tag, in onWakeLockAcquired() 189 mBatteryStats.noteStartWakelock(ownerUid, ownerPid, tag, historyTag, in onWakeLockAcquired() 212 mBatteryStats.noteLongPartialWakelockStart(tag, historyTag, workSource.get(i)); in onLongPartialWakeLockStart() 215 mBatteryStats.noteLongPartialWakelockStart(tag, historyTag, ownerUid); in onLongPartialWakeLockStart() 233 mBatteryStats.noteLongPartialWakelockFinish(tag, historyTag, workSource.get(i)); in onLongPartialWakeLockFinish() 236 mBatteryStats.noteLongPartialWakelockFinish(tag, historyTag, ownerUid); in onLongPartialWakeLockFinish() 265 mBatteryStats.noteChangeWakelockFromSource(workSource, ownerPid, tag, historyTag, in onWakeLockChanging() [all …]
|
/frameworks/opt/net/wifi/service/java/com/android/server/wifi/ |
D | WifiStateTracker.java | 37 private IBatteryStats mBatteryStats; field in WifiStateTracker 41 mBatteryStats = stats; in WifiStateTracker() 46 mBatteryStats.noteWifiState(state, null); in informWifiStateBatteryStats()
|
D | WifiLockManager.java | 41 private final IBatteryStats mBatteryStats; field in WifiLockManager 54 mBatteryStats = batteryStats; in WifiLockManager() 156 mBatteryStats.noteFullWifiLockReleasedFromSource(wl.mWorkSource); in updateWifiLockWorkSource() 158 mBatteryStats.noteFullWifiLockAcquiredFromSource(wl.mWorkSource); in updateWifiLockWorkSource() 191 mBatteryStats.noteFullWifiLockAcquiredFromSource(lock.mWorkSource); in addLock() 233 mBatteryStats.noteFullWifiLockReleasedFromSource(wifiLock.mWorkSource); in releaseLock()
|
D | WifiMulticastLockManager.java | 42 private final IBatteryStats mBatteryStats; field in WifiMulticastLockManager 55 mBatteryStats = batteryStats; in WifiMulticastLockManager() 148 mBatteryStats.noteWifiMulticastEnabled(uid); in acquireLock() 182 mBatteryStats.noteWifiMulticastDisabled(uid); in removeMulticasterLocked()
|
D | SupplicantStateTracker.java | 52 private final IBatteryStats mBatteryStats; field in SupplicantStateTracker 106 mBatteryStats = mFacade.getBatteryService(); in SupplicantStateTracker() 210 mBatteryStats.noteWifiSupplicantStateChanged(supplState, failedAuth); in sendSupplicantStateChangedBroadcast()
|
D | WifiInjector.java | 122 private final IBatteryStats mBatteryStats; field in WifiInjector 154 mBatteryStats = IBatteryStats.Stub.asInterface(mFrameworkFacade.getService( in WifiInjector() 156 mWifiStateTracker = new WifiStateTracker(mBatteryStats); in WifiInjector()
|
D | WifiStateMachine.java | 861 private final IBatteryStats mBatteryStats; field in WifiStateMachine 890 mBatteryStats = IBatteryStats.Stub.asInterface(mFacade.getService( in WifiStateMachine() 2109 mBatteryStats.noteWifiRunningChanged(mLastRunningWifiUids, in updateBatteryWorkSource() 2115 mBatteryStats.noteWifiRunning(mRunningWifiUids); in updateBatteryWorkSource() 2122 mBatteryStats.noteWifiStopped(mLastRunningWifiUids); in updateBatteryWorkSource() 2790 mBatteryStats.noteWifiOn(); in setWifiState() 2792 mBatteryStats.noteWifiOff(); in setWifiState() 2814 mBatteryStats.noteWifiOn(); in setWifiApState() 2816 mBatteryStats.noteWifiOff(); in setWifiApState() 3056 mBatteryStats.noteWifiRssiChanged(newRssi); in sendRssiChangeBroadcast()
|
/frameworks/base/core/java/android/os/ |
D | BatteryManager.java | 219 private final IBatteryStats mBatteryStats; field in BatteryManager 226 mBatteryStats = IBatteryStats.Stub.asInterface( in BatteryManager() 235 mBatteryStats = batteryStats; in BatteryManager() 247 return mBatteryStats.isCharging(); in isCharging()
|
/frameworks/base/services/core/java/com/android/server/connectivity/ |
D | DataConnectionStats.java | 41 private final IBatteryStats mBatteryStats; field in DataConnectionStats 50 mBatteryStats = BatteryStatsService.getService(); in DataConnectionStats() 94 mBatteryStats.notePhoneDataConnectionState(networkType, visible); in notePhoneDataConnectionState()
|
/frameworks/base/services/core/java/com/android/server/job/ |
D | JobServiceContext.java | 97 private final IBatteryStats mBatteryStats; field in JobServiceContext 177 mBatteryStats = batteryStats; in JobServiceContext() 241 mBatteryStats.noteJobStart(job.getBatteryName(), job.getSourceUid()); in executeRunnableJob() 709 mBatteryStats.noteJobFinish(mRunningJob.getBatteryName(), in closeAndCleanupJobLocked()
|
/frameworks/opt/net/wifi/tests/wifitests/src/com/android/server/wifi/scanner/ |
D | WifiScanningServiceTest.java | 93 @Mock IBatteryStats mBatteryStats; field in WifiScanningServiceTest 130 mWifiScannerImplFactory, mBatteryStats, mWifiInjector); in setUp() 405 mWifiScannerImplFactory, mBatteryStats); in construct() 524 verify(mBatteryStats).noteWifiScanStartedFromSource(eq(workSource)); in doSuccessfulSingleScan() 539 verify(mBatteryStats).noteWifiScanStoppedFromSource(eq(workSource)); in doSuccessfulSingleScan() 636 verifyNoMoreInteractions(mBatteryStats); in sendSingleScanRequestWhichFailsToStart() 672 verify(mBatteryStats).noteWifiScanStartedFromSource(eq(workSource)); in sendSingleScanRequestWhichFailsAfterStart() 683 verify(mBatteryStats).noteWifiScanStoppedFromSource(eq(workSource)); in sendSingleScanRequestWhichFailsAfterStart() 968 verify(mBatteryStats).noteWifiScanStartedFromSource(eq(workSource1)); in sendMultipleSingleScanRequestWhilePreviousScanRunning() 991 verify(mBatteryStats).noteWifiScanStoppedFromSource(eq(workSource1)); in sendMultipleSingleScanRequestWhilePreviousScanRunning() [all …]
|
/frameworks/base/services/core/java/com/android/server/display/ |
D | DisplayPowerController.java | 129 private final IBatteryStats mBatteryStats; field in DisplayPowerController 286 mBatteryStats = BatteryStatsService.getService(); in DisplayPowerController() 518 mBatteryStats.noteScreenState(mPowerState.getScreenState()); in initialize() 519 mBatteryStats.noteScreenBrightness(mPowerState.getScreenBrightness()); in initialize() 902 mBatteryStats.noteScreenState(state); 953 mBatteryStats.noteScreenBrightness(target);
|
/frameworks/base/services/core/java/com/android/server/am/ |
D | ProcessRecord.java | 58 private final BatteryStatsImpl mBatteryStats; // where to collect runtime statistics field in ProcessRecord 345 synchronized (mBatteryStats) { in dump() 346 wtime = mBatteryStats.getProcessWakeTime(info.uid, in dump() 439 mBatteryStats = _batteryStats; in ProcessRecord()
|
/frameworks/base/services/core/java/com/android/server/ |
D | TelephonyRegistry.java | 132 private final IBatteryStats mBatteryStats; field in TelephonyRegistry 297 mBatteryStats = BatteryStatsService.getService(); in TelephonyRegistry() 1457 mBatteryStats.notePhoneState(state.getState()); in broadcastServiceStateChanged() 1479 mBatteryStats.notePhoneSignalStrength(signalStrength); in broadcastSignalStrengthChanged() 1506 mBatteryStats.notePhoneOff(); in broadcastCallStateChanged() 1508 mBatteryStats.notePhoneOn(); in broadcastCallStateChanged()
|
D | BatteryService.java | 114 private final IBatteryStats mBatteryStats; field in BatteryService 165 mBatteryStats = BatteryStatsService.getService(); in BatteryService() 370 mBatteryStats.setBatteryState(mBatteryProps.batteryStatus, mBatteryProps.batteryHealth, in processValuesLocked()
|
D | DeviceIdleController.java | 118 private IBatteryStats mBatteryStats; field in DeviceIdleController 1049 mBatteryStats.noteDeviceIdleMode(msg.what == MSG_REPORT_IDLE_ON in handleMessage() 1070 mBatteryStats.noteDeviceIdleMode(BatteryStats.DEVICE_IDLE_MODE_OFF, in handleMessage() 1099 mBatteryStats.noteDeviceIdleMode(BatteryStats.DEVICE_IDLE_MODE_OFF, in handleMessage() 1399 mBatteryStats = BatteryStatsService.getService(); in onBootPhase() 1726 mBatteryStats.noteEvent(BatteryStats.HistoryItem.EVENT_TEMP_WHITELIST_START, in addPowerSaveTempWhitelistAppDirectInternal() 1783 mBatteryStats.noteEvent(BatteryStats.HistoryItem.EVENT_TEMP_WHITELIST_FINISH, in checkTempAppWhitelistTimeout()
|
D | NetworkManagementService.java | 219 private IBatteryStats mBatteryStats; field in NetworkManagementService 377 if (mBatteryStats != null) { in getBatteryStats() 378 return mBatteryStats; in getBatteryStats() 380 mBatteryStats = IBatteryStats.Stub.asInterface(ServiceManager.getService( in getBatteryStats() 382 return mBatteryStats; in getBatteryStats()
|
/frameworks/opt/net/wifi/service/java/com/android/server/wifi/scanner/ |
D | WifiScanningServiceImpl.java | 270 private final IBatteryStats mBatteryStats; field in WifiScanningServiceImpl 282 mBatteryStats = batteryStats; in WifiScanningServiceImpl() 666 mBatteryStats.noteWifiScanStartedFromSource(mScanWorkSource); in enter() 676 mBatteryStats.noteWifiScanStoppedFromSource(mScanWorkSource); in exit() 1878 mBatteryStats.noteWifiBatchedScanStartedFromSource(mWorkSource, csph); in reportBatchedScanStart() 1889 mBatteryStats.noteWifiBatchedScanStoppedFromSource(mWorkSource); in reportBatchedScanStop()
|
/frameworks/base/services/usage/java/com/android/server/usage/ |
D | UsageStatsService.java | 147 private IBatteryStats mBatteryStats; field in UsageStatsService 244 mBatteryStats = IBatteryStats.Stub.asInterface( in onBootPhase() 608 mBatteryStats.noteEvent(BatteryStats.HistoryItem.EVENT_PACKAGE_INACTIVE, in notifyBatteryStats() 611 mBatteryStats.noteEvent(BatteryStats.HistoryItem.EVENT_PACKAGE_ACTIVE, in notifyBatteryStats()
|
/frameworks/base/services/core/java/com/android/server/location/ |
D | GnssLocationProvider.java | 406 private final IBatteryStats mBatteryStats; field in GnssLocationProvider 707 mBatteryStats = IBatteryStats.Stub.asInterface(ServiceManager.getService( in GnssLocationProvider() 1298 mBatteryStats.noteStartGps(uid); in updateClientUids() 1316 mBatteryStats.noteStopGps(uid); in updateClientUids()
|