Here you can find the source of trySleepSeconds(int seconds)
public static boolean trySleepSeconds(int seconds)
//package com.java2s; //License from project: Open Source License public class Main { public static boolean trySleepSeconds(int seconds) { return trySleepMillis(seconds * 1000); }/*from w w w .ja v a 2 s . co m*/ public static boolean trySleepMillis(int millis) { try { Thread.sleep(millis); return true; } catch (Exception ex) { } return false; } }