answersLogoWhite

0


Best Answer

1) notify() is used to unblock one waiting thread. 2) notifyall() method is used to unblock all the threads in waiting state.

User Avatar

Wiki User

9y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: What is the difference between notify and notifyAll?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

What is the difference between consignee and notify party?

Consignee is the actual receiver of the cargo and the notify party is invoicing party who pays for the cargo


What is ment by thread interaction in java?

Two threads can interact with one another using the wait and notify methods. If one thread wants another thread to wait until it completes, it can use the wait method. similarly if it wants the other threads to know that it is done executing, it can use the notify or notifyall methods


How many methods does the Object class have?

The Object class has 11 methods (plus the constructor). They are: clone(), equals(), finalize(), getClass(), hashCode(), notify(), notifyAll(), toString(), wait(), wait(long timeout), wait(long timeout, int nanos).


What is notify function in java?

The notify() method is used in Thread Communication between two threads along with the wait() method


What is difference between synchronization and inter thread communication?

Synchronization is the process by which, access to the objects by threads are controlled and at at time only one thread can access an object. This is done to ensure that there are no dirty read/write operations. If multiple threads access the same data simultaneously, we may end up with inconsistent data. To avoid it, we place such code in synchronized blocks/methods to ensure integrity of data. Inter thread communication is the process by which java threads can communicate with one another. They communicate to one another through some commands like wait, notify, notifyall etc.


There are two classes class a and class b if class a wants to inform class b some important information it uses which Method?

notifyAll(),wait()


What is the difference between the word appraise and apprise?

The word appraise means to assess, judge or evaluate something. Meanwhile, the word apprise means to inform or notify someone about something. Many use the words incorrectly.


What is the future tense of notify?

It is notify. "I will notify you next week".


What is difference between as on and as at?

difference between as on and as at


How do you use notify in a sentence?

she had to notify me that she would not be attending


How do you notify k12 of cheating?

how do you notify k12 of cheating


What are the differences between California and Florida?

What is the difference between Florida and California What is the difference between Florida and California