Added in API level 24

OnAlarmListener

interface OnAlarmListener
android.app.AlarmManager.OnAlarmListener

Direct-notification alarms: the requester must be running continuously from the time the alarm is set to the time it is delivered, or delivery will fail. Only one-shot alarms can be set using this mechanism, not repeating alarms.

Summary

Public methods
abstract Unit

Callback method that is invoked by the system when the alarm time is reached.

Public methods

onAlarm

Added in API level 24
abstract fun onAlarm(): Unit

Callback method that is invoked by the system when the alarm time is reached.