GeeCON Prague 2014*
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes Which all calls stops the thread. Seeking advice to answer the exam questions. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "Which all calls stops the thread. Seeking advice to answer the exam questions." Watch "Which all calls stops the thread. Seeking advice to answer the exam questions." New topic
Author

Which all calls stops the thread. Seeking advice to answer the exam questions.

Sanjay Mishra
Ranch Hand

Joined: Jul 08, 2000
Posts: 84
Hello,
I have found invariably 1 or more questions in all the mocks
over the calls which stops the thread.
While performing search in Javaranch I have found a nice discussion over this ("InterruptedException" july 26, 2000). Explanation in this posting have cleared most of my doubts
but still am worried about my answer choice in real exam.

1. sleep
2. stop
3. wait
4. yield
5. interrupt
6. suspend
7. waitforId/waitforData
8. blocked for io
9. If the current thread starts the new thread
10. Thread with higher priority is in the pool.
Ajith has explained that that sleep() does not stop the thread
whereas interrupt stops the thread. While Kai's notes and
Hunt's mock exam says just the opposite.
Also waitforId/waitforData does not stop the thread but blocks.
However, all the mock exam includes that as answer which will
stop the thread.
Please advice me the answer which I should be choosen in
the exam.
Please suggest the answer for all the 10 situations given above.
Regards
Sanjay
Sanjay Mishra
Ranch Hand

Joined: Jul 08, 2000
Posts: 84
Hello Friends,
I am still looking for reply.
Will someone comment on this post.
Thanks
Regards
Sanjay.
 
GeeCON Prague 2014
 
subject: Which all calls stops the thread. Seeking advice to answer the exam questions.