which two CANNOT directly cause a thread to stop executing? a. exiting from a synchronized block b. calling the wait method c. calling the notify method on an object d. calling a read method on an InputStream object e. calling the setPriority method on a Thread object I choose d and e. Am I right?
<B>-Kaleem Haqqi</B><BR>Java is mind work. Having the right frame of mind is essential.
I Guess , Ans a) n e) are correct b) Calling wait method 'll stop da Thread , until its notified on da same object c) Calling notify on some object , CAN stop current thread , if there are any other Thread(s) to be notified , waiting on same object d) Read() n write() methods in Streams are Blocking , it means they do not return until done their job ------------------ Gagan (/^_^\) SCJP2 Die-hard JavaMonk -- little Java a day , keeps u going .
Gagan (/^_^\) SCJP2 SCWCD IBM486 <br />Die-hard JavaMonk -- little Java a day, keeps you going.<br /><a href="http://www.objectfirst.com/blog" target="_blank" rel="nofollow">My Blog</a>