Saturday, March 30, 2002 09:32 AM
To get the difference between now and some date in the future for a sleep call you can do something like:
long current = System.currentTimeMillis();
Calendar cal = new Calendar();
cal.set(2002, 2, 29, 5 25);
long future = cal.getTimeInMillis();
sleep(future - current);
Probably want some error checking to make sure that the calendar date is after the current time, etc. But you get the idea?