java singleton synchronized example
Example: How to make a singleton class synchronized
public enum Singleton { INSTANCE; private String value; public void setValue(String value) { this.value = value; } public String getValue() { return value; }}