Additional Methods to Support ExceptionListener

Chapter 14 - Waiting for the Full Timeout

Java Thread Programming
Paul Hyde
  Copyright 1999 Sams Publishing

Summary
As you build larger applications in Java, you will sometimes need to specify limits as to how long you want one thread to wait for a certain condition to be met. Because the wait() method returns when notified and returns when it times out, steps need to be taken to keep track of how much more time (if any) should be spent waiting for the condition to be met. In this chapter, I showed you a technique for doing this by calculating an ending time before waiting, and then waiting again if this time has not yet been reached.

Toc


Java Thread Programming
Java Thread Programming
ISBN: 0672315858
EAN: 2147483647
Year: 2005
Pages: 149
Authors: Paul Hyde

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net