3

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?

3 Answers 3

5

That would be a Monitor

Sign up to request clarification or add additional context in comments.

Comments

2

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

Comments

2

Doug Lea factored Object's monitor (synchronized) and the wait/notify mechanisms into the Lock and Condition interfaces respectively.

These support richer and more fine-grained functionality than Object's monitor, but are explicitly providing the same functionality.

Calling wait/notify Condition is fairly standard.

See this question for some usage details on Locks/Condition

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.