sleep current thread for milliseconds - Android java.lang

Android examples for java.lang:Thread

Description

sleep current thread for milliseconds

Demo Code


//package com.java2s;

public class Main {
    public static void sleep(int ms) {
        try {/*from  ww  w.  j  a v  a  2  s  .  co m*/
            Thread.sleep(ms);
        } catch (InterruptedException e) {
        }
    }
}

Related Tutorials