Java tutorial
//package com.java2s; //License from project: Apache License public class Main { /** * endless sleep until interrupted. * * @param millis * @return true:normal end, false: Interrupted */ public final static void endlessSleep() { try { Thread.sleep(Long.MAX_VALUE); } catch (InterruptedException e) { // omit } } }