/packages/apps/Settings/tests/unit/src/com/android/settings/applications/ |
D | AppStateAlarmsAndRemindersBridgeTest.java | 50 private AlarmManager mAlarmManager; field in AppStateAlarmsAndRemindersBridgeTest 131 bridge.mAlarmManager = mAlarmManager; in createPermissionState_SeaGrantedNoUeaNoAllowlist() 135 doReturn(true).when(mAlarmManager).hasScheduleExactAlarm(TEST_PACKAGE, in createPermissionState_SeaGrantedNoUeaNoAllowlist() 151 bridge.mAlarmManager = mAlarmManager; in createPermissionState_requestsBothSeaDeniedNoAllowlist() 155 doReturn(false).when(mAlarmManager).hasScheduleExactAlarm(TEST_PACKAGE, in createPermissionState_requestsBothSeaDeniedNoAllowlist() 173 bridge.mAlarmManager = mAlarmManager; in createPermissionState_requestsNoneNoAllowlist() 177 doReturn(false).when(mAlarmManager).hasScheduleExactAlarm(TEST_PACKAGE, in createPermissionState_requestsNoneNoAllowlist() 193 bridge.mAlarmManager = mAlarmManager; in createPermissionState_requestsOnlyUeaNoAllowlist() 197 doReturn(false).when(mAlarmManager).hasScheduleExactAlarm(TEST_PACKAGE, in createPermissionState_requestsOnlyUeaNoAllowlist() 213 bridge.mAlarmManager = mAlarmManager; in createPermissionState_requestsNoneButAllowlisted() [all …]
|
/packages/apps/WallpaperPicker2/src/com/android/wallpaper/module/ |
D | DefaultAlarmManagerWrapper.java | 27 private AlarmManager mAlarmManager; field in DefaultAlarmManagerWrapper 30 mAlarmManager = (AlarmManager) context.getSystemService(Context.ALARM_SERVICE); in DefaultAlarmManagerWrapper() 35 mAlarmManager.set(type, triggerAtMillis, operation); in set() 41 mAlarmManager.setWindow(type, windowStartMillis, windowLengthMillis, operation); in setWindow() 47 mAlarmManager.setInexactRepeating(type, triggerAtMillis, intervalMillis, operation); in setInexactRepeating() 52 mAlarmManager.cancel(operation); in cancel()
|
/packages/providers/CalendarProvider/src/com/android/providers/calendar/ |
D | CalendarAlarmManager.java | 126 private AlarmManager mAlarmManager; field in CalendarAlarmManager 134 mAlarmManager = (AlarmManager) context.getSystemService(Context.ALARM_SERVICE); in initializeWithContext() 482 if (mAlarmManager == null) return; in set() 483 mAlarmManager.set(type, triggerAtTime, operation); in set() 487 if (mAlarmManager == null) return; in setAndAllowWhileIdle() 488 mAlarmManager.setAndAllowWhileIdle(type, triggerAtTime, operation); in setAndAllowWhileIdle() 492 if (mAlarmManager == null) return; in setExact() 493 mAlarmManager.setExact(type, triggerAtTime, operation); in setExact() 497 if (mAlarmManager == null) return; in setExactAndAllowWhileIdle() 498 mAlarmManager.setExactAndAllowWhileIdle(type, triggerAtTime, operation); in setExactAndAllowWhileIdle() [all …]
|
/packages/apps/Settings/src/com/android/settings/fuelgauge/batteryusage/ |
D | PeriodicJobManager.java | 41 private final AlarmManager mAlarmManager; field in PeriodicJobManager 52 if (sSingleton == null || sSingleton.mAlarmManager == null) { in getInstance() 60 this.mAlarmManager = context.getSystemService(AlarmManager.class); in PeriodicJobManager() 65 if (mAlarmManager == null) { in refreshJob() 79 mAlarmManager.setExactAndAllowWhileIdle( in refreshJob() 91 if (mAlarmManager != null) { in cancelJob() 92 mAlarmManager.cancel(pendingIntent); in cancelJob()
|
/packages/modules/Telephony/services/QualifiedNetworksService/tests/src/com/android/telephony/qns/ |
D | QnsTimerTest.java | 65 @Mock private AlarmManager mAlarmManager; field in QnsTimerTest 76 when(mContext.getSystemService(AlarmManager.class)).thenReturn(mAlarmManager); in setup() 99 verify(mAlarmManager) in testRegisterTimerForScreenOff() 113 verify(mAlarmManager, never()) in testRegisterTimerForScreenOn() 133 verify(mAlarmManager).cancel(isA(PendingIntent.class)); in testUnregisterTimerForScreenOff() 143 verify(mAlarmManager, never()).cancel(isA(PendingIntent.class)); in testUnregisterTimerForScreenOn() 153 verify(mAlarmManager) in testUpdateTimerTypeToAlarm() 167 verify(mAlarmManager) in testTimerExpired() 176 verify(mAlarmManager).cancel(isA(PendingIntent.class)); in testTimerExpired() 197 verify(mAlarmManager) in testMultipleTimerRegistered() [all …]
|
/packages/modules/Wifi/service/tests/wifitests/src/com/android/server/wifi/ |
D | WifiPseudonymManagerTest.java | 92 @Mock AlarmManager mAlarmManager; field in WifiPseudonymManagerTest 115 mWifiContext, mWifiInjector, mClock, mAlarmManager, mLooper); in setUp() 151 verify(mAlarmManager, times(1)) in retrievePseudonymOnFailureTimeout_expiredPseudonym_scheduleRefresh() 175 verifyNoMoreInteractions(mAlarmManager); in retrievePseudonymOnFailureTimeout_noPseudonym_notScheduleRefresh() 313 verify(mAlarmManager, times(1)) in setPseudonymAndScheduleRefresh_freshPseudonym_schedule() 332 verify(mAlarmManager, times(1)) in retrieveOobPseudonymIfNeeded_noPseudonym_scheduleRefresh() 352 verify(mAlarmManager, times(2)) in retrieveOobPseudonymIfNeeded_freshPseudonym_scheduleRefresh() 379 verify(mAlarmManager, times(2)) in retrieveOobPseudonymIfNeeded_expiredPseudonym_scheduleRefresh() 398 verify(mAlarmManager, times(2)) in retrieveOobPseudonymWithRateLimit_expiredPseudonym_scheduleRefresh() 411 verify(mAlarmManager, never()) in retrieveOobPseudonymWithRateLimit_emptyPseudonym_noScheduleRefresh() [all …]
|
D | TwtManagerTest.java | 95 private AlarmManager mAlarmManager; field in TwtManagerTest 113 mAlarmManager = mTestAlarmManager.getAlarmManager(); in setUp() 114 when(mWifiInjector.getAlarmManager()).thenReturn(mAlarmManager); in setUp() 239 InOrder inOrderAlarm = inOrder(mAlarmManager); in testSetupTwtSession() 251 inOrderAlarm.verify(mAlarmManager).set(eq(AlarmManager.ELAPSED_REALTIME), anyLong(), in testSetupTwtSession() 256 inOrderAlarm.verify(mAlarmManager).cancel(any(AlarmManager.OnAlarmListener.class)); in testSetupTwtSession() 263 inOrderAlarm.verify(mAlarmManager).set(eq(AlarmManager.ELAPSED_REALTIME), anyLong(), in testSetupTwtSession() 296 InOrder inOrderAlarm = inOrder(mAlarmManager); in testTeardownTwtSession() 310 inOrderAlarm.verify(mAlarmManager).set(eq(AlarmManager.ELAPSED_REALTIME), anyLong(), in testTeardownTwtSession() 327 inOrderAlarm.verify(mAlarmManager).set(eq(AlarmManager.ELAPSED_REALTIME), anyLong(), in testTeardownTwtSession() [all …]
|
D | WifiHealthMonitorTest.java | 131 private TestAlarmManager mAlarmManager; field in WifiHealthMonitorTest 185 mAlarmManager = new TestAlarmManager(); in setUp() 187 .thenReturn(mAlarmManager.getAlarmManager()); in setUp() 382 mAlarmManager.dispatch(WifiHealthMonitor.POST_BOOT_DETECTION_TIMER_TAG); in makeSerializedExample() 424 mAlarmManager.dispatch(WifiHealthMonitor.POST_BOOT_DETECTION_TIMER_TAG); in testReadWriteAndSWChange() 458 mAlarmManager.dispatch(WifiHealthMonitor.POST_BOOT_DETECTION_TIMER_TAG); in testSerializationDeserialization() 492 long waitTimeMs = mAlarmManager in testTimerMultiDayRun() 498 mAlarmManager.dispatch(WifiHealthMonitor.DAILY_DETECTION_TIMER_TAG); in testTimerMultiDayRun() 500 waitTimeMs = mAlarmManager in testTimerMultiDayRun() 507 mAlarmManager.dispatch(WifiHealthMonitor.DAILY_DETECTION_TIMER_TAG); in testTimerMultiDayRun() [all …]
|
D | WifiNetworkFactoryTest.java | 161 @Mock AlarmManager mAlarmManager; field in WifiNetworkFactoryTest 298 mNetworkCapabilities, mActivityManager, mAlarmManager, mAppOpsManager, in setUp() 868 verify(mAlarmManager).cancel(any(OnAlarmListener.class)); in testPeriodicScanCancelOnReleaseNetworkRequestWithSpecifier() 895 verify(mAlarmManager).cancel(mPeriodicScanListenerArgumentCaptor.getValue()); in testPeriodicScanCancelOnUserSelectNetwork() 1332 verify(mAlarmManager).cancel(any(OnAlarmListener.class)); in testNetworkSpecifierHandleUserSelectionConnectToNetwork() 1437 verify(mAlarmManager).cancel(any(OnAlarmListener.class)); in testNetworkSpecifierHandleUserSelectionConnectToExistingSavedNetwork() 1696 verify(mAlarmManager).cancel(any(OnAlarmListener.class)); in testNetworkSpecifierHandleUserSelectionReject() 1720 mInOrder = inOrder(mAlarmManager, mClientModeManager, mConnectHelper); in testNetworkSpecifierHandleConnectionTimeout() 1750 mInOrder = inOrder(mAlarmManager, mClientModeManager, mConnectHelper); in testNetworkSpecifierHandleConnectionTriggerFailure() 1759 mInOrder.verify(mAlarmManager).cancel( in testNetworkSpecifierHandleConnectionTriggerFailure() [all …]
|
D | SoftApManagerTest.java | 184 private TestAlarmManager mAlarmManager; field in SoftApManagerTest 293 verify(mAlarmManager.getAlarmManager(), isBridged ? times(2) : times(1)).setExact( in mockSoftApInfoUpdateAndVerifyAfterSapStarted() 304 verify(mAlarmManager.getAlarmManager()).setExact(anyInt(), in mockSoftApInfoUpdateAndVerifyAfterSapStarted() 309 verify(mAlarmManager.getAlarmManager()).setExact(anyInt(), in mockSoftApInfoUpdateAndVerifyAfterSapStarted() 340 mAlarmManager = new TestAlarmManager(); in setUp() 342 .thenReturn(mAlarmManager.getAlarmManager()); in setUp() 1667 verify(mAlarmManager.getAlarmManager()).cancel(eq(timerOnTestInterface)); in testCallbackForClientUpdateToZeroWhenLeaveSoftapStarted() 1678 verify(mAlarmManager.getAlarmManager()).cancel(eq(timerOnTestInterface)); in testCallbackForClientUpdateToZeroWhenLeaveSoftapStarted() 1918 verify(mAlarmManager.getAlarmManager()).cancel( in testConfigChangeToSmallAndClientAddBlockListCauseClientDisconnect() 1965 verify(mAlarmManager.getAlarmManager(), never()).setExact(anyInt(), anyLong(), in schedulesTimeoutTimerOnStart() [all …]
|
/packages/modules/Wifi/service/tests/wifitests/src/com/android/server/wifi/scanner/ |
D | WificondScannerTest.java | 144 verify(mAlarmManager.getAlarmManager(), never()).cancel(any(PendingIntent.class)); in externalScanResultsDoNotCauseSpuriousTimerCancellationOrCrash() 145 verify(mAlarmManager.getAlarmManager(), never()) in externalScanResultsDoNotCauseSpuriousTimerCancellationOrCrash() 147 verify(mAlarmManager.getAlarmManager(), never()).cancel(isNull(PendingIntent.class)); in externalScanResultsDoNotCauseSpuriousTimerCancellationOrCrash() 148 verify(mAlarmManager.getAlarmManager(), never()) in externalScanResultsDoNotCauseSpuriousTimerCancellationOrCrash() 169 verify(mAlarmManager.getAlarmManager(), never()).cancel(any(PendingIntent.class)); in externalScanResultsAfterOurScanDoNotCauseSpuriousTimerCancellationOrCrash() 170 verify(mAlarmManager.getAlarmManager(), times(1)) in externalScanResultsAfterOurScanDoNotCauseSpuriousTimerCancellationOrCrash() 172 verify(mAlarmManager.getAlarmManager(), never()).cancel(isNull(PendingIntent.class)); in externalScanResultsAfterOurScanDoNotCauseSpuriousTimerCancellationOrCrash() 173 verify(mAlarmManager.getAlarmManager(), never()) in externalScanResultsAfterOurScanDoNotCauseSpuriousTimerCancellationOrCrash() 194 mAlarmManager.dispatch(WificondScannerImpl.TIMEOUT_ALARM_TAG); in lateScanResultsDoNotCauseSpuriousTimerCancellationOrCrash() 201 verify(mAlarmManager.getAlarmManager(), never()).cancel(any(PendingIntent.class)); in lateScanResultsDoNotCauseSpuriousTimerCancellationOrCrash() [all …]
|
/packages/modules/Wifi/service/java/com/android/server/wifi/hotspot2/ |
D | ANQPRequestManager.java | 50 private final AlarmManager mAlarmManager; field in ANQPRequestManager 139 mAlarmManager = wifiInjector.getAlarmManager(); in ANQPRequestManager() 190 mAlarmManager.set( in processNextRequest() 227 mAlarmManager.cancel(mAnqpRequestListener); in onRequestCompleted() 322 mAlarmManager.cancel(mAnqpRequestListener); in clear()
|
/packages/modules/IPsec/src/java/com/android/internal/net/ipsec/ike/utils/ |
D | IkeAlarm.java | 36 protected final AlarmManager mAlarmManager; field in IkeAlarm 41 mAlarmManager = alarmConfig.context.getSystemService(AlarmManager.class); in IkeAlarm() 142 mAlarmManager.cancel(mPendingIntent); in cancel() 148 mAlarmManager.setExactAndAllowWhileIdle( in schedule()
|
/packages/apps/Test/connectivity/PMC/src/com/android/pmc/ |
D | WifiConnScanReceiver.java | 26 private AlarmManager mAlarmManager; field in WifiConnScanReceiver 34 mAlarmManager = alarmManager; in WifiConnScanReceiver() 67 mAlarmManager.setAndAllowWhileIdle(AlarmManager.ELAPSED_REALTIME_WAKEUP, in scheduleConnScan() 75 mAlarmManager.cancel(mAlarmIntent); in cancelConnScan()
|
D | PMCMainActivity.java | 80 private AlarmManager mAlarmManager; field in PMCMainActivity 96 mAlarmManager = (AlarmManager) getSystemService(Context.ALARM_SERVICE); in onCreate() 103 mBleScanReceiver = new BleScanReceiver(this, mAlarmManager); in onCreate() 104 mGattPMCReceiver = new GattPMCReceiver(this, mAlarmManager); in onCreate() 105 mA2dpReceiver = new A2dpReceiver(this, mAlarmManager); in onCreate() 208 mAlarmManager, mPIDownload); in startDownloadFile() 233 mConnSR = new WifiConnScanReceiver(this, mIntervalMillis, mAlarmManager, mPIConnScan); in startConnectivityScan() 271 this, scanSettings, mIntervalMillis, mAlarmManager, mPIGScan); in startGscan()
|
D | WifiGScanReceiver.java | 31 private AlarmManager mAlarmManager; field in WifiGScanReceiver 41 mAlarmManager = alarmManager; in WifiGScanReceiver() 73 mAlarmManager.setAndAllowWhileIdle(AlarmManager.ELAPSED_REALTIME_WAKEUP, in scheduleGscan() 81 mAlarmManager.cancel(mAlarmIntent); in cancelGScan()
|
D | WifiDownloadReceiver.java | 31 private AlarmManager mAlarmManager; field in WifiDownloadReceiver 42 mAlarmManager = alarmManager; in WifiDownloadReceiver() 77 mAlarmManager.setAndAllowWhileIdle(AlarmManager.ELAPSED_REALTIME_WAKEUP, in scheduleDownload() 85 mAlarmManager.cancel(mAlarmIntent); in cancelDownload()
|
D | BleScanReceiver.java | 48 private final AlarmManager mAlarmManager; field in BleScanReceiver 146 mAlarmManager.setExactAndAllowWhileIdle( in firstAlarm() 180 mAlarmManager.setExactAndAllowWhileIdle( in repeatAlarm() 236 mAlarmManager = alarmManager; in BleScanReceiver()
|
/packages/modules/Wifi/service/tests/wifitests/src/com/android/server/wifi/rtt/ |
D | RttServiceImplTest.java | 119 private TestAlarmManager mAlarmManager; field in RttServiceImplTest 222 mAlarmManager = new TestAlarmManager(); in setUp() 224 .thenReturn(mAlarmManager.getAlarmManager()); in setUp() 225 mInOrder = inOrder(mAlarmManager.getAlarmManager(), mockContext); in setUp() 367 mAlarmManager.getAlarmManager()); in testRangingFlow() 450 mAlarmManager.getAlarmManager()); in testRangingFlowUsingAwarePeerHandles() 572 mAlarmManager.getAlarmManager()); in testRangingFlowHalFailure() 610 mAlarmManager.getAlarmManager()); in testRangingRequestWithoutRuntimePermission() 692 mAlarmManager.getAlarmManager()); in testBinderDeathOfRangingApp() 732 mAlarmManager.getAlarmManager()); in testBinderDeathWithWorkSource() [all …]
|
/packages/modules/Bluetooth/android/app/src/com/android/bluetooth/btservice/ |
D | MetricsLogger.java | 72 private AlarmManager mAlarmManager = null; field in MetricsLogger 226 if (mAlarmManager == null) { in scheduleDrains() 227 mAlarmManager = mContext.getSystemService(AlarmManager.class); in scheduleDrains() 229 mAlarmManager.set( in scheduleDrains() 268 mAlarmManager = null; in close() 276 mAlarmManager.cancel(mOnAlarmListener); in cancelPendingDrain()
|
/packages/modules/Telephony/services/QualifiedNetworksService/src/com/android/telephony/qns/ |
D | QnsTimer.java | 58 private final AlarmManager mAlarmManager; field in QnsTimer 74 mAlarmManager = mContext.getSystemService(AlarmManager.class); in QnsTimer() 211 mAlarmManager.cancel(mPendingIntent); in updateToShortestDelay() 223 mAlarmManager.cancel(mPendingIntent); in clearAllTimers() 235 mAlarmManager.setExactAndAllowWhileIdle( in setupAlarmFor()
|
/packages/modules/Scheduling/service/java/com/android/server/scheduling/ |
D | RebootReadinessManagerService.java | 84 private final AlarmManager mAlarmManager; field in RebootReadinessManagerService 230 mAlarmManager = context.getSystemService(AlarmManager.class); in RebootReadinessManagerService() 307 mAlarmManager.cancel(mPollStateListener); in cancelPendingReboot() 362 mAlarmManager.setExact(AlarmManager.RTC_WAKEUP, in pollRebootReadinessState() 399 AlarmManager.AlarmClockInfo alarmClockInfo = mAlarmManager.getNextAlarmClock(); in checkSystemComponentsState() 503 AlarmManager.AlarmClockInfo alarmClockInfo = mAlarmManager.getNextAlarmClock(); in noteRebootReadinessStateChanged() 511 mAlarmManager.setExact(AlarmManager.RTC_WAKEUP, in noteRebootReadinessStateChanged()
|
/packages/apps/Settings/src/com/android/settings/applications/ |
D | AppStateAlarmsAndRemindersBridge.java | 48 AlarmManager mAlarmManager; field in AppStateAlarmsAndRemindersBridge 59 mAlarmManager = context.getSystemService(AlarmManager.class); in AppStateAlarmsAndRemindersBridge() 98 final boolean seaGranted = mAlarmManager.hasScheduleExactAlarm(packageName, userId); in createPermissionState()
|
/packages/modules/Scheduling/tests/unittests/src/com/android/server/scheduling/ |
D | RebootReadinessUnitTest.java | 91 private AlarmManager mAlarmManager; field in RebootReadinessUnitTest 154 mAlarmManager = spy(mMockContext.getSystemService(AlarmManager.class)); in setup() 162 doReturn(mAlarmManager).when(mMockContext).getSystemService(eq(AlarmManager.class)); in setup() 163 doCallRealMethod().when(mAlarmManager).setExact(anyInt(), anyLong(), anyString(), any( in setup() 168 when(mAlarmManager.getNextAlarmClock()).thenReturn(null); in setup() 369 when(mAlarmManager.getNextAlarmClock()).thenReturn(alarm); in testAlarmClockBlocksReboot() 374 when(mAlarmManager.getNextAlarmClock()).thenReturn(alarm); in testAlarmClockBlocksReboot() 480 when(mAlarmManager.getNextAlarmClock()).thenReturn(alarm); in testAlarmClockCheckWhileReadyToReboot()
|
/packages/modules/Wifi/service/tests/wifitests/src/com/android/server/wifi/hotspot2/ |
D | ANQPRequestManagerTest.java | 111 private TestAlarmManager mAlarmManager; field in ANQPRequestManagerTest 127 mAlarmManager = new TestAlarmManager(); in setUp() 129 when(mWifiInjector.getAlarmManager()).thenReturn(mAlarmManager.getAlarmManager()); in setUp() 399 assertTrue(mAlarmManager.isPending(ANQP_REQUEST_ALARM_TAG)); in testWaitResponseEnabled() 401 mAlarmManager.dispatch(ANQP_REQUEST_ALARM_TAG); in testWaitResponseEnabled()
|