William Seemann
William Seemann

Reputation: 3530

Android Intent for new day or significant time changes

Is there an intent in Android that is broadcasted on significant time changes such as a new day. I'm looking for something similar to the significant time change notification that is broadcasted in iOS. I'm trying to schedule processing to occur at the start of each day. I know this possible with AlarmManager but I wanted to avoid scheduling my own alarm if there is another way.

Upvotes: 2

Views: 1565

Answers (1)

Cat
Cat

Reputation: 67502

The only time-related Intents in Android are:

There is no "significant time change" intent, I'm afraid. The best I can suggest is to register under ACTION_TIME_TICK and check if the time is equal to midnight or, as you said, using AlarmManager.

You can find a full list of available intents in the documentation (hit contol+F and find "Standard Activity Actions" to get right to the list). "Broadcast Actions" are the ones you'd be interested in for this problem.

Upvotes: 9

Related Questions