schedule Timer Interval - Android java.util

Android examples for java.util:Timer

Description

schedule Timer Interval

Demo Code


//package com.java2s;

import java.util.Timer;
import java.util.TimerTask;

public class Main {
    public static Timer scheduleInterval(int msec, TimerTask timerTask) {
        Timer timer = new Timer();
        timer.schedule(timerTask, 0, msec);//?~???b??u??N??
        return timer;
    }//from w w w . j a  v a2 s  .co m
}

Related Tutorials