在Android中重新启动后保存警报

时间:2013-01-29 07:55:33

标签: android

我是android新手。我正在阅读手册,并阅读以下内容:

Registered alarms are retained while the device is asleep (and can optionally wake the device up if they go off during that time), but will be cleared if it is turned off and rebooted

警报可以保存在应用程序中。如果是的你能告诉我怎么做。

能否请您提供代码。

1 个答案:

答案 0 :(得分:0)

这应该让你去。 简而言之,您可以减轻您的应用程序对警报本身的监视。 相反,您告诉系统为您跟踪它,并且只需创建一个应该在闹钟响起后被系统唤醒的类。

http://www.vogella.com/articles/AndroidServices/article.html#scheduleservice_scheduling