package com.laundrylangpickcargo.util;
/**
* Created by Sinaan on 2018/10/12.
*/
import android.os.Handler;
import android.os.Message;
import android.os.SystemClock;
/**
* 双向的计时器,先倒计时然后正计时,也可以只正计时
*/
public abstract class CountTwowayTimer {
/**
* Millis since epoch when alarm should stop.
*/
private final long mMillisInFuture;
/**
* The interval in millis that the user receives callbacks
*/
private final long mCountTwowayInterval;
private long mStopTimeInFuture;
/**
* boolean representing if the timer was cancelled
*/
private boolean mCancelled = false;
/**
* @param millisInFuture The number of millis in the future from the call
* to {@link #start()} until the countTwoway is done}
* is called.
* 距离目标时间的总间隔时长
* 为正,距离目标时间的间隔,开始倒计时,倒
双向计时,倒计时完成后继续正计时
最新推荐文章于 2025-02-13 16:59:56 发布