public final class

AlarmClock

extends Object
java.lang.Object
   ↳ android.provider.AlarmClock

Class Overview

The AlarmClock provider contains an Intent action and extras that can be used to start an Activity to set a new alarm in an alarm clock application. Applications that wish to receive the ACTION_SET_ALARM Intent should create an activity to handle the Intent that requires the permission com.android.alarm.permission.SET_ALARM. Applications that wish to create a new alarm should use Context.startActivity() so that the user has the option of choosing which alarm clock application to use.

Summary

Constants
String ACTION_SET_ALARM Activity Action: Set an alarm.
String EXTRA_HOUR Activity Extra: The hour of the alarm being set.
String EXTRA_MESSAGE Activity Extra: Provide a custom message for the alarm.
String EXTRA_MINUTES Activity Extra: The minutes of the alarm being set.
Public Constructors
AlarmClock()
[Expand]
Inherited Methods
From class java.lang.Object

Constants

public static final String ACTION_SET_ALARM

Since: API Level 9

Activity Action: Set an alarm.

Input: Nothing.

Output: Nothing.

Constant Value: "android.intent.action.SET_ALARM"

public static final String EXTRA_HOUR

Since: API Level 9

Activity Extra: The hour of the alarm being set.

This value can be passed as an extra field to the Intent created with ACTION_SET_ALARM. If it is not provided, the behavior is undefined and is up to the application. The value is an integer and ranges from 0 to 23.

Constant Value: "android.intent.extra.alarm.HOUR"

public static final String EXTRA_MESSAGE

Since: API Level 9

Activity Extra: Provide a custom message for the alarm.

This can be passed as an extra field in the Intent created with ACTION_SET_ALARM.

Constant Value: "android.intent.extra.alarm.MESSAGE"

public static final String EXTRA_MINUTES

Since: API Level 9

Activity Extra: The minutes of the alarm being set.

This value can be passed as an extra field to the Intent created with ACTION_SET_ALARM. If it is not provided, the behavior is undefined and is up to the application. The value is an integer and ranges from 0 to 59.

Constant Value: "android.intent.extra.alarm.MINUTES"

Public Constructors

public AlarmClock ()

Since: API Level 9