Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
在 Java 中,有一个带有“wait”、“notify”和“notifyall”功能的“monitor”同步机制。据说使用“notifyall”而不是“notify”可以有效避免死锁,但我无法真正理解这一点。谁能帮忙解释一下这句话?