Lines Matching refs:alarm
40 * Built-in zen condition provider for alarm-clock-based conditions.
42 * <p>If the user's next alarm is within a lookahead threshold (config, default 12hrs), advertise
45 * <p>The next alarm is defined as {@link AlarmManager#getNextAlarmClock(int)}, which does not
46 * survive a reboot. Maintain the illusion of a consistent next alarm value by holding on to
134 private boolean isWithinLookaheadThreshold(AlarmClockInfo alarm) {
135 if (alarm == null) return false;
136 final long delta = NextAlarmTracker.getEarlyTriggerTime(alarm) - System.currentTimeMillis();
140 private void notifyCondition(Uri id, AlarmClockInfo alarm, int state, String reason) {
141 final String formattedAlarm = alarm == null ? "" : mTracker.formatAlarm(alarm);
143 + " alarm=" + formattedAlarm + " reason=" + reason);
206 // next alarm changed since subscription, consider obsolete
209 // next alarm outside threshold or in the past, condition = false
212 // next alarm within threshold and in the future, condition = true