Home
last modified time | relevance | path

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

1234

/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/support/compat/java/android/support/v4/app/
DAlarmManagerCompat.java19 import android.app.AlarmManager;
55 public static void setAlarmClock(AlarmManager alarmManager, long triggerTime, in setAlarmClock()
58 alarmManager.setAlarmClock(new AlarmManager.AlarmClockInfo(triggerTime, showIntent), in setAlarmClock()
61 AlarmManagerCompat.setExact(alarmManager, AlarmManager.RTC_WAKEUP, triggerTime, in setAlarmClock()
113 public static void setAndAllowWhileIdle(AlarmManager alarmManager, int type, in setAndAllowWhileIdle()
158 public static void setExact(AlarmManager alarmManager, int type, long triggerAtMillis, in setExact()
218 public static void setExactAndAllowWhileIdle(AlarmManager alarmManager, int type, in setExactAndAllowWhileIdle()
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/policy/
DNextAlarmControllerImpl.java19 import android.app.AlarmManager;
37 private AlarmManager mAlarmManager;
38 private AlarmManager.AlarmClockInfo mNextAlarm;
41 mAlarmManager = (AlarmManager) context.getSystemService(Context.ALARM_SERVICE); in NextAlarmControllerImpl()
44 filter.addAction(AlarmManager.ACTION_NEXT_ALARM_CLOCK_CHANGED); in NextAlarmControllerImpl()
66 || action.equals(AlarmManager.ACTION_NEXT_ALARM_CLOCK_CHANGED)) { in onReceive()
DNextAlarmController.java17 import android.app.AlarmManager;
25 void onNextAlarmChanged(AlarmManager.AlarmClockInfo nextAlarm); in onNextAlarmChanged()
/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/core/java/com/android/internal/util/
DWakeupMessage.java19 import android.app.AlarmManager;
39 public class WakeupMessage implements AlarmManager.OnAlarmListener {
40 private final AlarmManager mAlarmManager;
54 mAlarmManager = (AlarmManager) context.getSystemService(Context.ALARM_SERVICE); in WakeupMessage()
84 AlarmManager.ELAPSED_REALTIME_WAKEUP, when, mCmdName, this, mHandler); in schedule()
/frameworks/base/core/tests/utiltests/src/com/android/internal/util/
DWakeupMessageTest.java22 import android.app.AlarmManager;
50 @Mock AlarmManager mAlarmManager;
55 ArgumentCaptor<AlarmManager.OnAlarmListener> mListenerCaptor =
56 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()
/frameworks/base/tests/utils/SleepUtils/AlarmService/src/com/android/testing/alarmservice/
DAlarmImpl.java19 import android.app.AlarmManager;
51 AlarmManager am = (AlarmManager) mContext.getSystemService(Context.ALARM_SERVICE); in setAlarmAndWait()
55 am.set(AlarmManager.ELAPSED_REALTIME_WAKEUP, atTime, pi); in setAlarmAndWait()
/frameworks/support/samples/Support4Demos/src/com/example/android/supportv4/content/
DSimpleWakefulController.java22 import android.app.AlarmManager;
64 AlarmManager am = (AlarmManager)getSystemService(ALARM_SERVICE);
65 am.set(AlarmManager.RTC_WAKEUP, calendar.getTimeInMillis(), sender);
/frameworks/base/core/java/android/app/
DIAlarmManager.aidl19 import android.app.AlarmManager;
34 … String listenerTag, in WorkSource workSource, in AlarmManager.AlarmClockInfo alarmClock); in set()
39 AlarmManager.AlarmClockInfo getNextAlarmClock(int userId); in getNextAlarmClock()
/frameworks/base/packages/SystemUI/src/com/android/systemui/doze/
DDozeUi.java19 import android.app.AlarmManager;
38 private final AlarmManager mAlarmManager;
43 private final AlarmManager.OnAlarmListener mTimeTick;
48 public DozeUi(Context context, AlarmManager alarmManager, DozeMachine machine, in DozeUi()
119 mAlarmManager.setExact(AlarmManager.ELAPSED_REALTIME_WAKEUP, in scheduleTimeTick()
DDozeFactory.java19 import android.app.AlarmManager;
39 AlarmManager alarmManager = context.getSystemService(AlarmManager.class); in assembleMachine()
69 DozeMachine machine, Handler handler, AlarmManager alarmManager) { in createDozeUi()
/frameworks/base/tests/utils/SleepUtils/WakeLoopService/src/android/test/wakeuploop/
DWakeLoopService.java19 import android.app.AlarmManager;
77 AlarmManager am = (AlarmManager)getSystemService(Context.ALARM_SERVICE); in onStartCommand()
86 am.set(AlarmManager.ELAPSED_REALTIME_WAKEUP, atTime, pi); in onStartCommand()
DWakeUpCall.java19 import android.app.AlarmManager;
46 AlarmManager am = (AlarmManager) context.getSystemService(Context.ALARM_SERVICE); in onReceive()
82 am.set(AlarmManager.ELAPSED_REALTIME_WAKEUP, atTime, pi); in onReceive()
/frameworks/base/core/tests/coretests/src/android/app/activity/
DSetTimeZonePermissionsTest.java19 import android.app.AlarmManager;
30 private AlarmManager mAlarm;
38 mAlarm = (AlarmManager) mContext.getSystemService(Context.ALARM_SERVICE); in setUp()
/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()
150 mAlarmManager.setExact(AlarmManager.RTC_WAKEUP, now + 60000, mAlarmIntent); in performTimeUpdate()
/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()
206 final AlarmManager alarms = (AlarmManager) mContext.getSystemService(Context.ALARM_SERVICE); in updateAlarm()
217 alarms.setExact(AlarmManager.RTC_WAKEUP, time, pendingIntent); in updateAlarm()
224 final AlarmManager.AlarmClockInfo info = mAlarmManager.getNextAlarmClock( in getNextAlarm()
251 filter.addAction(AlarmManager.ACTION_NEXT_ALARM_CLOCK_CHANGED); in setRegistered()
/frameworks/base/services/core/java/com/android/server/
DAlarmManagerService.java21 import android.app.AlarmManager;
79 import static android.app.AlarmManager.RTC_WAKEUP;
80 import static android.app.AlarmManager.RTC;
81 import static android.app.AlarmManager.ELAPSED_REALTIME_WAKEUP;
82 import static android.app.AlarmManager.ELAPSED_REALTIME;
117 new Intent(AlarmManager.ACTION_NEXT_ALARM_CLOCK_CHANGED)
184 private final SparseArray<AlarmManager.AlarmClockInfo> mNextAlarmClockForUser =
186 private final SparseArray<AlarmManager.AlarmClockInfo> mTmpSparseAlarmClockArray =
193 private final SparseArray<AlarmManager.AlarmClockInfo> mHandlerSparseAlarmClockArray =
740 if ((b.flags&AlarmManager.FLAG_STANDALONE) == 0 && b.canHold(whenElapsed, maxWhen)) { in attemptCoalesceLocked()
[all …]
DLockSettingsStrongAuth.java25 import android.app.AlarmManager;
26 import android.app.AlarmManager.OnAlarmListener;
66 private AlarmManager mAlarmManager;
71 mAlarmManager = context.getSystemService(AlarmManager.class); in LockSettingsStrongAuth()
145 mAlarmManager.set(AlarmManager.ELAPSED_REALTIME, when, STRONG_AUTH_TIMEOUT_ALARM_TAG, in handleScheduleStrongAuthTimeout()
/frameworks/base/services/backup/java/com/android/server/backup/
DKeyValueBackupJob.java19 import android.app.AlarmManager;
42 static final long BATCH_INTERVAL = 4 * AlarmManager.INTERVAL_HOUR;
51 private static final long MAX_DEFERRAL = AlarmManager.INTERVAL_DAY;
/frameworks/base/services/core/java/com/android/server/job/controllers/
DTimeController.java19 import android.app.AlarmManager;
20 import android.app.AlarmManager.OnAlarmListener;
52 private AlarmManager mAlarmService = null;
147 mAlarmService = (AlarmManager) mContext.getSystemService(Context.ALARM_SERVICE); in ensureAlarmServiceLocked()
294 mAlarmService.set(AlarmManager.ELAPSED_REALTIME_WAKEUP, alarmTimeElapsed, in updateAlarmWithListenerLocked()
295 AlarmManager.WINDOW_HEURISTIC, 0, tag, listener, null, new WorkSource(uid)); in updateAlarmWithListenerLocked()
/frameworks/base/services/devicepolicy/java/com/android/server/devicepolicy/
DNetworkLoggingHandler.java19 import android.app.AlarmManager;
20 import android.app.AlarmManager.OnAlarmListener;
65 private final AlarmManager mAlarmManager;
142 mAlarmManager.setWindow(AlarmManager.ELAPSED_REALTIME_WAKEUP, when, in scheduleBatchFinalization()
/frameworks/opt/net/wifi/service/java/com/android/server/wifi/
DWifiConnectivityManager.java21 import android.app.AlarmManager;
140 private final AlarmManager mAlarmManager;
199 private final AlarmManager.OnAlarmListener mRestartScanListener =
200 new AlarmManager.OnAlarmListener() {
208 private class RestartSingleScanListener implements AlarmManager.OnAlarmListener {
223 private final AlarmManager.OnAlarmListener mWatchdogListener =
224 new AlarmManager.OnAlarmListener() {
232 private final AlarmManager.OnAlarmListener mPeriodicScanTimerListener =
233 new AlarmManager.OnAlarmListener() {
546 mAlarmManager = (AlarmManager) context.getSystemService(Context.ALARM_SERVICE); in WifiConnectivityManager()
[all …]
DWifiConfigStore.java19 import android.app.AlarmManager;
93 private final AlarmManager mAlarmManager;
117 private final AlarmManager.OnAlarmListener mBufferedWriteListener =
118 new AlarmManager.OnAlarmListener() {
147 mAlarmManager = (AlarmManager) context.getSystemService(Context.ALARM_SERVICE); in WifiConfigStore()
302 mAlarmManager.set(AlarmManager.ELAPSED_REALTIME_WAKEUP, in startBufferedWriteAlarm()
/frameworks/opt/net/wifi/service/java/com/android/server/wifi/scanner/
DWificondScannerImpl.java19 import android.app.AlarmManager;
62 private final AlarmManager mAlarmManager;
110 AlarmManager.OnAlarmListener mScanPeriodListener = new AlarmManager.OnAlarmListener() {
118 AlarmManager.OnAlarmListener mScanTimeoutListener = new AlarmManager.OnAlarmListener() {
132 mAlarmManager = (AlarmManager) mContext.getSystemService(Context.ALARM_SERVICE); in WificondScannerImpl()
385 mAlarmManager.set(AlarmManager.ELAPSED_REALTIME_WAKEUP, in processPendingScans()
435 mAlarmManager.set(AlarmManager.ELAPSED_REALTIME_WAKEUP, in processPendingScans()
876 private final AlarmManager mAlarmManager;
896 public HwPnoDebouncer(WifiNative wifiNative, AlarmManager alarmManager, in HwPnoDebouncer()
950 private final AlarmManager.OnAlarmListener mAlarmListener =
[all …]

1234