java.lang.Object | |
↳ | android.provider.AlarmClock |
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.
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. | |||||||||
String | EXTRA_SKIP_UI | Activity Extra: Optionally skip the application UI. |
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
|
Activity Action: Set an alarm.
Input: Nothing.
Output: Nothing.
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.
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.
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.
Activity Extra: Optionally skip the application UI.
This value can be passed as an extra field to the Intent created with ACTION_SET_ALARM. If true, the application is asked to bypass any intermediate UI and instead pop a toast indicating the result then finish the Activity. If false, the application may display intermediate UI like a confirmation dialog or alarm settings. The default is false.