Handle 定时任务
2018-04-10 本文已影响18人
贝贝beibei96
每隔100毫秒执行一次
private Handler handler;
private Runnable runnable;
handler = new Handler();
runnable = () -> {
// do something
handler.postDelayed(runnable, 100);
};
handler.postDelayed(runnable, 100);