Something like:
Get the current time.
Get the next time out of the db.
determine the difference and sleep for that long.
wakeup, do your stuff.
start all over.
Hope this helps,
Stan
-----Original Message-----
From: AKS: Boban Acimovic [SMTP:[EMAIL PROTECTED]]
Sent: Wednesday, May 05, 1999 5:37 AM
To: [EMAIL PROTECTED]
Subject: Real time
I want to write small Java application that will send me e-mail at the right time.
I already know how to mail, but how to work that action exactly in some predefined time.
I will keep dates and times in database and I know how to access data.
I thought to use Thread.sleep() etc. and I can work out that way, checking local time,
but is there any API that I can use? On example, to say do something in 8:30 tomorrow.
Any help will be appreciated. Thanks.
___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".
Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html
