@Target(METHOD)
@Retention(SOURCE)
public @interface Synchronized
For non-static methods, a field named $lock is used, and for static methods,
$LOCK is used. These will be generated if needed and if they aren't already present. The contents
of the fields will be serializable.
Complete documentation is found at the project lombok features page for @Synchronized.
| Modifier and Type | Optional Element | Description |
|---|---|---|
java.lang.String |
value |
Optional: specify the name of a different field to lock on.
|
java.lang.String value
Copyright © 2009-2018 The Project Lombok Authors, licensed under the MIT licence.