Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How should the notify wait mechanism of Java be called?

What is an appropriate name? I read notify/wait should barely used for anything else, but building condition queues. Another possible name might be thread coordination. In the Java concurrency tutorial its named Guarded Blocks. Actually I find no one of these suitable. Is there a better keyword to describe this mechanism?

like image 698
Konrad Reiche Avatar asked Jan 19 '23 09:01

Konrad Reiche


2 Answers

That would be a Monitor

like image 57
M Platvoet Avatar answered Jan 22 '23 00:01

M Platvoet


Thread coordination seems reasonable. The wait/notify methods coordinate via the object's monitor. Monitor is maybe the concept you are looking for.

like image 23
sudocode Avatar answered Jan 21 '23 22:01

sudocode