File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Java in General and the fly likes thread Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "thread" Watch "thread" New topic
Author

thread

sri jaisi
Greenhorn

Joined: Sep 02, 2006
Posts: 23
we use wait.notify,notifyall in threads.but why we have these three methods in object class rather than in thread class

thankz
Deepak Bala
Bartender

Joined: Feb 24, 2006
Posts: 6657
    
    5

Every object has a lock of its own. When you say wait() you want that object's lock and thats why the methods are defined in the Object class.


SCJP 6 articles - SCJP 5/6 mock exams - More SCJP Mocks
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: thread
 
Similar Threads
threads
Local Variable
multithreading
How to kill a user thread forcefully?
Thread/ Runnable