Does android support real time events? If so how could they be implemented?

后端 未结 2 978
余生分开走
余生分开走 2021-01-24 20:39

I\'m using Android Studio to develop and application and I\'d like that when a certain moment of time is met the application performs some defined action.

I know I could

相关标签:
2条回答
  • 2021-01-24 21:16

    Yes take a look at AlarmManager it will let you do an action in a specific time

    0 讨论(0)
  • 2021-01-24 21:24

    If you need to check some external databases once every X seconds/minutes, then you may consider using a Handler & Runnable with postDelayed() method to achieve what you need.

    0 讨论(0)
提交回复
热议问题