Synchronization
Coordinating threads so shared state is accessed safely and changes are visible.
What is Synchronization in Java?
Synchronization — Coordinating threads so shared state is accessed safely and changes are visible.
class Counter {
private int value;
synchronized void increment() {
value++;
}
}
Level: Master · More Java terms at this level
Updated