I need to build a background task that runs every 10/15 minutes (doesn't really matter, either is good), even when the application is not running.
How can I accomplish this? I can't seem the wrap my head around this.
I read I could use some sort of runnable() functionality or use a background services or AlarmManager. I was thinking of a background service, since it also must be done when the application itself is not running.
What is a better way of doing this and how could I do it?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…