- type
- One of AlarmManager.ELAPSED_REALTIME, AlarmManager.ELAPSED_REALTIME_WAKEUP, AlarmManager.RTC, or AlarmManager.RTC_WAKEUP.
- triggerAtMillis
- time in milliseconds that the alarm should first go off, using the appropriate clock (depending on the alarm type). This is inexact: the alarm will not fire before this time, but there may be a delay of almost an entire alarm interval before the first invocation of the alarm.
- intervalMillis
- interval in milliseconds between subsequent repeats of the alarm. Prior to API 19, if this is one of INTERVAL_FIFTEEN_MINUTES, INTERVAL_HALF_HOUR, INTERVAL_HOUR, INTERVAL_HALF_DAY, or INTERVAL_DAY then the alarm will be phase-aligned with other alarms to reduce the number of wakeups. Otherwise, the alarm will be set as though the application had called AlarmManager.SetRepeating(AlarmType, System.Int64, System.Int64, System.Int64). As of API 19, all repeating alarms will be inexact and subject to batching with other alarms regardless of their stated repeat interval.
- operation
- Action to perform when the alarm goes off; typically comes from PendingIntent.GetBroadcast(Android.Content.Context, System.Int32, System.Int32, System.Int32).
Schedule a repeating alarm that has inexact trigger time requirements; for example, an alarm that repeats every hour, but not necessarily at the top of every hour. These alarms are more power-efficient than the strict recurrences traditionally supplied by AlarmManager.SetRepeating(AlarmType, System.Int64, System.Int64, System.Int64), since the system can adjust alarms' delivery times to cause them to fire simultaneously, avoiding waking the device from sleep more than necessary.
Your alarm's first trigger will not be before the requested time, but it might not occur for almost a full interval after that time. In addition, while the overall period of the repeating alarm will be as requested, the time between any two successive firings of the alarm may vary. If your application demands very low jitter, use one-shot alarms with an appropriate window instead; see AlarmManager.SetWindow(AlarmType, System.Int64, System.Int64, System.Int64) and AlarmManager.SetExact(AlarmType, System.Int64, System.Int64).
As of API 19, all repeating alarms are inexact. Because this method has been available since API 3, your application can safely call it and be assured that it will get similar behavior on both current and older versions of Android.