AlarmManager.SetExact Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
| SetExact(AlarmType, Int64, PendingIntent) |
Schedule an alarm to be delivered precisely at the stated time. |
| SetExact(AlarmType, Int64, String, AlarmManager+IOnAlarmListener, Handler) |
Schedule an alarm to be delivered precisely at the stated time. |
SetExact(AlarmType, Int64, PendingIntent)
Schedule an alarm to be delivered precisely at the stated time.
[Android.Runtime.Register("setExact", "(IJLandroid/app/PendingIntent;)V", "GetSetExact_IJLandroid_app_PendingIntent_Handler")]
[Android.Runtime.RequiresPermission("android.permission.SCHEDULE_EXACT_ALARM")]
public virtual void SetExact (Android.App.AlarmType type, long triggerAtMillis, Android.App.PendingIntent? operation);
[<Android.Runtime.Register("setExact", "(IJLandroid/app/PendingIntent;)V", "GetSetExact_IJLandroid_app_PendingIntent_Handler")>]
[<Android.Runtime.RequiresPermission("android.permission.SCHEDULE_EXACT_ALARM")>]
abstract member SetExact : Android.App.AlarmType * int64 * Android.App.PendingIntent -> unit
override this.SetExact : Android.App.AlarmType * int64 * Android.App.PendingIntent -> unit
Parameters
- type
- AlarmType
type of alarm.
- triggerAtMillis
- Int64
time in milliseconds that the alarm should go off, using the appropriate clock (depending on the alarm type).
- operation
- PendingIntent
Action to perform when the alarm goes off;
typically comes from PendingIntent#getBroadcast
IntentSender.getBroadcast().
- Attributes
Remarks
Java documentation for android.app.AlarmManager.setExact(int, long, android.app.PendingIntent).
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.
See also
- <xref:Android.App.AlarmManager.Set(Android.App.AlarmType%2c+System.Int64%2c+System.Int64)>
- <xref:Android.App.AlarmManager.SetRepeating(Android.App.AlarmType%2c+System.Int64%2c+System.Int64%2c+System.Int64)>
- <xref:Android.App.AlarmManager.SetWindow(Android.App.AlarmType%2c+System.Int64%2c+System.Int64%2c+System.Int64)>
- Cancel(PendingIntent)
- SendBroadcast(Intent)
- <xref:Android.Content.Context.RegisterReceiver(Android.Content.BroadcastReceiver%2c+Android.Content.IntentFilter)>
- FilterEquals(Intent)
Applies to
SetExact(AlarmType, Int64, String, AlarmManager+IOnAlarmListener, Handler)
Schedule an alarm to be delivered precisely at the stated time.
[Android.Runtime.Register("setExact", "(IJLjava/lang/String;Landroid/app/AlarmManager$OnAlarmListener;Landroid/os/Handler;)V", "GetSetExact_IJLjava_lang_String_Landroid_app_AlarmManager_OnAlarmListener_Landroid_os_Handler_Handler", ApiSince=24)]
[Android.Runtime.RequiresPermission("android.permission.SCHEDULE_EXACT_ALARM")]
public virtual void SetExact (Android.App.AlarmType type, long triggerAtMillis, string? tag, Android.App.AlarmManager.IOnAlarmListener? listener, Android.OS.Handler? targetHandler);
[<Android.Runtime.Register("setExact", "(IJLjava/lang/String;Landroid/app/AlarmManager$OnAlarmListener;Landroid/os/Handler;)V", "GetSetExact_IJLjava_lang_String_Landroid_app_AlarmManager_OnAlarmListener_Landroid_os_Handler_Handler", ApiSince=24)>]
[<Android.Runtime.RequiresPermission("android.permission.SCHEDULE_EXACT_ALARM")>]
abstract member SetExact : Android.App.AlarmType * int64 * string * Android.App.AlarmManager.IOnAlarmListener * Android.OS.Handler -> unit
override this.SetExact : Android.App.AlarmType * int64 * string * Android.App.AlarmManager.IOnAlarmListener * Android.OS.Handler -> unit
Parameters
- type
- AlarmType
type of alarm.
- triggerAtMillis
- Int64
time in milliseconds that the alarm should go off, using the appropriate clock (depending on the alarm type).
- tag
- String
- listener
- AlarmManager.IOnAlarmListener
- targetHandler
- Handler
- Attributes
Remarks
Java documentation for android.app.AlarmManager.setExact(int, long, android.app.PendingIntent).
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.