Get Synchronized Map from Java HashMap example : HashMap « Collections Data Structure « Java
- Java
- Collections Data Structure
- HashMap
Get Synchronized Map from Java HashMap example
import java.util.Collections;
import java.util.HashMap;
import java.util.Map;
public class Main {
public static void main(String[] args) {
HashMap hashMap = new HashMap();
Map map = Collections.synchronizedMap(hashMap);
}
}
Related examples in the same category