The Artima Developer Community
Sponsored Link

Legacy Java Answers Forum
February 2001

Advertisement

Advertisement

This page contains an archived post to the Java Answers Forum made prior to February 25, 2002. If you wish to participate in discussions, please visit the new Artima Forums.

Message:

stoping thread

Posted by siva on March 02, 2001 at 11:16 PM

stopping thread is like throwing exception(Error).
if a thread is stopped when it is in synchronized block
it will simply throw ThreadDeathException and get terminated without notifing other threads which are waiting on that object.To avoid this try to catch that exception and call
notifyAll() and rethrow that exception.




Replies:

Sponsored Links



Google
  Web Artima.com   
Copyright © 1996-2009 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use - Advertise with Us