• Post Reply Bookmark Topic Watch Topic
  • New Topic

SCJP Threads: Here we come!  RSS feed

Ranch Hand
Posts: 75
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi ranchers,
u guys are great! please 4 d sake of those of us that are about to tke d scjp exams i would like to make suggest that every interested rancher should write a list of at most 7 key points to take note of when answering thread questions in scjp exam. (if u're already certified , ur contribution will be most appreciated)
Lets please make them as simple as possible. I start from 1-7. please next rancher continue for the next no.
1. wait(),notify()/notifyAll() MUST be declared within synchronized code,else an IllegalMonitorState (RT) Exception is generated.
2.sleep() MUST throw InterruptedException.
3.a thread that implements runnable must declare its run method correctly(public void run()).
4.whenever start() is called twice on the same thread, an IllegalThreadStateException(RT) is thrown.
5.if the start() and run() methods are swapped in a thread, there will be compilation but no output at runtime.
6. a class that extends thread CANNOT extend another class.
7.suspend(),resume(),stop() and countstackframes ae depraecated in Java2
thanks u'll,
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!