Home
last modified time | relevance | path

Searched refs:AlarmManager (Results 1 – 25 of 132) sorted by relevance

123456

/frameworks/base/tests/utils/testutils/java/android/app/test/
DTestAlarmManager.java26 import android.app.AlarmManager;
44 private final AlarmManager mAlarmManager;
50 mAlarmManager = mock(AlarmManager.class); in TestAlarmManager()
52 any(AlarmManager.OnAlarmListener.class), any(Handler.class)); in TestAlarmManager()
54 anyString(), any(AlarmManager.OnAlarmListener.class), any(Handler.class)); in TestAlarmManager()
56 .when(mAlarmManager).cancel(any(AlarmManager.OnAlarmListener.class)); in TestAlarmManager()
59 public AlarmManager getAlarmManager() { in getAlarmManager()
140 AlarmManager.OnAlarmListener listener, Handler handler) { in answer()
147 public void answer(AlarmManager.OnAlarmListener listener) { in answer()
163 private final AlarmManager.OnAlarmListener mListener;
[all …]
/frameworks/base/packages/SystemUI/src/com/android/systemui/util/
DAlarmTimeout.java19 import android.app.AlarmManager;
27 public class AlarmTimeout implements AlarmManager.OnAlarmListener {
33 private final AlarmManager mAlarmManager;
34 private final AlarmManager.OnAlarmListener mListener;
39 public AlarmTimeout(AlarmManager alarmManager, AlarmManager.OnAlarmListener listener, in AlarmTimeout()
76 mAlarmManager.setExact(AlarmManager.ELAPSED_REALTIME_WAKEUP, in schedule()
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/bluetooth/
DBluetoothDiscoverableTimeoutReceiver.java20 import android.app.AlarmManager;
42 AlarmManager alarmManager = in setDiscoverableAlarm()
43 (AlarmManager) context.getSystemService (Context.ALARM_SERVICE); in setDiscoverableAlarm()
53 alarmManager.set(AlarmManager.RTC_WAKEUP, alarmTime, pending); in setDiscoverableAlarm()
65 AlarmManager alarmManager = in cancelDiscoverableAlarm()
66 (AlarmManager) context.getSystemService (Context.ALARM_SERVICE); in cancelDiscoverableAlarm()
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/policy/
DNextAlarmControllerImpl.java19 import android.app.AlarmManager;
42 private AlarmManager mAlarmManager;
43 private AlarmManager.AlarmClockInfo mNextAlarm;
49 mAlarmManager = (AlarmManager) context.getSystemService(Context.ALARM_SERVICE); in NextAlarmControllerImpl()
52 filter.addAction(AlarmManager.ACTION_NEXT_ALARM_CLOCK_CHANGED); in NextAlarmControllerImpl()
74 || action.equals(AlarmManager.ACTION_NEXT_ALARM_CLOCK_CHANGED)) { in onReceive()
DNextAlarmController.java17 import android.app.AlarmManager;
25 void onNextAlarmChanged(AlarmManager.AlarmClockInfo nextAlarm); in onNextAlarmChanged()
DZenModeControllerImpl.java20 import android.app.AlarmManager;
69 private final AlarmManager mAlarmManager;
104 mAlarmManager = (AlarmManager) context.getSystemService(Context.ALARM_SERVICE); in ZenModeControllerImpl()
172 final AlarmManager.AlarmClockInfo info = mAlarmManager.getNextAlarmClock(mUserId); in getNextAlarm()
182 final IntentFilter filter = new IntentFilter(AlarmManager.ACTION_NEXT_ALARM_CLOCK_CHANGED); in onUserSwitched()
289 if (AlarmManager.ACTION_NEXT_ALARM_CLOCK_CHANGED.equals(intent.getAction())) {
/frameworks/base/core/tests/utiltests/src/com/android/internal/util/
DWakeupMessageTest.java22 import android.app.AlarmManager;
51 @Mock AlarmManager mAlarmManager;
56 ArgumentCaptor<AlarmManager.OnAlarmListener> mListenerCaptor =
57 ArgumentCaptor.forClass(AlarmManager.OnAlarmListener.class);
109 verify(mAlarmManager).setExact(eq(AlarmManager.ELAPSED_REALTIME_WAKEUP), eq(when), in scheduleAndVerifyAlarm()
110 eq(TEST_CMD_NAME), any(AlarmManager.OnAlarmListener.class), eq(mHandler)); in scheduleAndVerifyAlarm()
180 verify(mAlarmManager).setExact(eq(AlarmManager.ELAPSED_REALTIME_WAKEUP), eq(when), in scheduleRunnable()
181 eq(TEST_CMD_NAME), any(AlarmManager.OnAlarmListener.class), eq(mHandler)); in scheduleRunnable()
/frameworks/base/core/java/com/android/internal/util/
DWakeupMessage.java19 import android.app.AlarmManager;
39 public class WakeupMessage implements AlarmManager.OnAlarmListener {
40 private final AlarmManager mAlarmManager;
89 private static AlarmManager getAlarmManager(Context context) { in getAlarmManager()
90 return (AlarmManager) context.getSystemService(Context.ALARM_SERVICE); in getAlarmManager()
101 AlarmManager.ELAPSED_REALTIME_WAKEUP, when, mCmdName, this, mHandler); in schedule()
/frameworks/base/core/java/android/app/
DIAlarmManager.aidl19 import android.app.AlarmManager;
35 … String listenerTag, in WorkSource workSource, in AlarmManager.AlarmClockInfo alarmClock); in set()
42 AlarmManager.AlarmClockInfo getNextAlarmClock(int userId); in getNextAlarmClock()
/frameworks/base/core/tests/coretests/src/android/app/activity/
DSetTimeZonePermissionsTest.java19 import android.app.AlarmManager;
31 private AlarmManager mAlarm;
39 mAlarm = (AlarmManager) mContext.getSystemService(Context.ALARM_SERVICE); in setUp()
/frameworks/base/services/core/java/com/android/server/timezonedetector/
DTimeZoneDetectorCallbackImpl.java20 import android.app.AlarmManager;
80 AlarmManager alarmManager = mContext.getSystemService(AlarmManager.class); in setDeviceTimeZone()
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/keyguard/
DKeyguardSliceProviderTest.java29 import android.app.AlarmManager;
78 private AlarmManager mAlarmManager;
172AlarmManager.AlarmClockInfo alarmClockInfo = new AlarmManager.AlarmClockInfo(in16Hours, null); in schedulesAlarm12hBefore()
177 verify(mAlarmManager).setExact(eq(AlarmManager.RTC), eq(triggerAt), anyString(), any(), in schedulesAlarm12hBefore()
184AlarmManager.AlarmClockInfo alarmClockInfo = new AlarmManager.AlarmClockInfo(in16Hours, null); in updatingNextAlarmInvalidatesSlice()
249 verify(mAlarmManager).cancel(any(AlarmManager.OnAlarmListener.class)); in onDestroy_unregisterListeners()
/frameworks/opt/net/wifi/tests/wifitests/src/com/android/server/wifi/scanner/
DWificondScannerTest.java25 import android.app.AlarmManager;
113 .cancel(any(AlarmManager.OnAlarmListener.class)); in externalScanResultsDoNotCauseSpuriousTimerCancellationOrCrash()
116 .cancel(isNull(AlarmManager.OnAlarmListener.class)); in externalScanResultsDoNotCauseSpuriousTimerCancellationOrCrash()
138 .cancel(any(AlarmManager.OnAlarmListener.class)); in externalScanResultsAfterOurScanDoNotCauseSpuriousTimerCancellationOrCrash()
141 .cancel(isNull(AlarmManager.OnAlarmListener.class)); in externalScanResultsAfterOurScanDoNotCauseSpuriousTimerCancellationOrCrash()
169 .cancel(any(AlarmManager.OnAlarmListener.class)); in lateScanResultsDoNotCauseSpuriousTimerCancellationOrCrash()
172 .cancel(isNull(AlarmManager.OnAlarmListener.class)); in lateScanResultsDoNotCauseSpuriousTimerCancellationOrCrash()
/frameworks/base/services/core/java/com/android/server/notification/
DScheduleConditionProvider.java20 import android.app.AlarmManager;
70 private AlarmManager mAlarmManager;
163 mAlarmManager = (AlarmManager) mContext.getSystemService(Context.ALARM_SERVICE); in evaluateSubscriptions()
220 final AlarmManager alarms = (AlarmManager) mContext.getSystemService(Context.ALARM_SERVICE); in updateAlarm()
231 alarms.setExact(AlarmManager.RTC_WAKEUP, time, pendingIntent); in updateAlarm()
238 final AlarmManager.AlarmClockInfo info = mAlarmManager.getNextAlarmClock( in getNextAlarm()
256 filter.addAction(AlarmManager.ACTION_NEXT_ALARM_CLOCK_CHANGED); in setRegistered()
DCountdownConditionProvider.java19 import android.app.AlarmManager;
115 final AlarmManager alarms = (AlarmManager) in onSubscribe()
132 alarms.setExact(AlarmManager.RTC_WAKEUP, mTime, pendingIntent); in onSubscribe()
/frameworks/base/tests/DozeTest/src/com/android/dreams/dozetest/
DDozeTestDream.java19 import android.app.AlarmManager;
58 private AlarmManager mAlarmManager;
78 mAlarmManager = (AlarmManager)getSystemService(Context.ALARM_SERVICE); in onCreate()
149 mAlarmManager.setExact(AlarmManager.RTC_WAKEUP, now + 60000, mAlarmIntent); in performTimeUpdate()
/frameworks/base/services/core/java/com/android/server/timedetector/
DTimeDetectorStrategyCallbackImpl.java20 import android.app.AlarmManager;
50 @NonNull private final AlarmManager mAlarmManager;
60 mAlarmManager = Objects.requireNonNull(context.getSystemService(AlarmManager.class)); in TimeDetectorStrategyCallbackImpl()
/frameworks/base/apex/jobscheduler/service/java/com/android/server/job/controllers/idle/
DDeviceIdlenessTracker.java21 import android.app.AlarmManager;
43 private AlarmManager mAlarm;
56 private AlarmManager.OnAlarmListener mIdleAlarmListener = () -> {
81 mAlarm = (AlarmManager) context.getSystemService(Context.ALARM_SERVICE); in startTracking()
214 mAlarm.setWindow(AlarmManager.ELAPSED_REALTIME_WAKEUP, in maybeScheduleIdlenessCheck()
/frameworks/base/packages/SystemUI/src/com/android/systemui/doze/
DDozeFactory.java20 import android.app.AlarmManager;
52 private final AlarmManager mAlarmManager;
68 AsyncSensorManager asyncSensorManager, AlarmManager alarmManager, in DozeFactory()
140 DozeHost host, AlarmManager alarmManager, AmbientDisplayConfiguration config, in createDozeTriggers()
152 DozeMachine machine, Handler handler, AlarmManager alarmManager, in createDozeUi()
DDozePauser.java19 import android.app.AlarmManager;
33 public DozePauser(Handler handler, DozeMachine machine, AlarmManager alarmManager, in DozePauser()
/frameworks/base/apex/jobscheduler/service/java/com/android/server/job/controllers/
DTimeController.java23 import android.app.AlarmManager;
24 import android.app.AlarmManager.OnAlarmListener;
74 private AlarmManager mAlarmService = null;
225 mAlarmService = (AlarmManager) mContext.getSystemService(Context.ALARM_SERVICE); in ensureAlarmServiceLocked()
386 ? AlarmManager.ELAPSED_REALTIME : AlarmManager.ELAPSED_REALTIME_WAKEUP; in setDelayExpiredAlarmLocked()
402 updateAlarmWithListenerLocked(DEADLINE_TAG, AlarmManager.ELAPSED_REALTIME_WAKEUP, in setDeadlineExpiredAlarmLocked()
410 private void updateAlarmWithListenerLocked(String tag, @AlarmManager.AlarmType int alarmType, in updateAlarmWithListenerLocked()
420 AlarmManager.WINDOW_HEURISTIC, 0, tag, listener, null, ws); in updateAlarmWithListenerLocked()
/frameworks/base/services/core/java/com/android/server/twilight/
DTwilightService.java21 import android.app.AlarmManager;
50 implements AlarmManager.OnAlarmListener, Handler.Callback, LocationListener {
64 protected AlarmManager mAlarmManager;
122 mAlarmManager = (AlarmManager) c.getSystemService(Context.ALARM_SERVICE); in onBootPhase()
237 mAlarmManager.setExact(AlarmManager.RTC, triggerAtMillis, TAG, this, mHandler); in updateTwilightState()
/frameworks/base/services/core/java/com/android/server/pm/permission/
DOneTimePermissionUserManager.java23 import android.app.AlarmManager;
51 private final @NonNull AlarmManager mAlarmManager;
81 mAlarmManager = context.getSystemService(AlarmManager.class); in OneTimePermissionUserManager()
182 private class PackageInactivityListener implements AlarmManager.OnAlarmListener {
307 mAlarmManager.setExact(AlarmManager.RTC_WAKEUP, revokeTime, LOG_TAG, this, in setAlarmLocked()
/frameworks/base/services/devicepolicy/java/com/android/server/devicepolicy/
DNetworkLoggingHandler.java21 import android.app.AlarmManager;
22 import android.app.AlarmManager.OnAlarmListener;
74 private final AlarmManager mAlarmManager;
160 mAlarmManager.setWindow(AlarmManager.ELAPSED_REALTIME_WAKEUP, when, in scheduleBatchFinalization()
/frameworks/base/services/core/java/com/android/server/locksettings/
DLockSettingsStrongAuth.java23 import android.app.AlarmManager;
24 import android.app.AlarmManager.OnAlarmListener;
104 private final AlarmManager mAlarmManager;
128 public AlarmManager getAlarmManager(Context context) { in getAlarmManager()
129 return context.getSystemService(AlarmManager.class); in getAlarmManager()
265 mAlarmManager.set(AlarmManager.ELAPSED_REALTIME, nextAlarmTime, in rescheduleStrongAuthTimeoutAlarm()
306 mAlarmManager.set(AlarmManager.ELAPSED_REALTIME, nextAlarmTime, in handleScheduleNonStrongBiometricTimeout()
397 mAlarmManager.set(AlarmManager.ELAPSED_REALTIME, nextAlarmTime, in handleScheduleNonStrongBiometricIdleTimeout()

123456