HashMap
- Since Java 1.2
- Allows null key and value
- Poor performance in highly threaded applications
- Not much scalable
- Throws a ConcurrentModificationException
- Faster in non-multi threading applications
ConcurrentHashMap
- Since Java 1.5
- Doesn't allow null key or value
- Better performance in Highly threaded applications
- Highly scalable
- Do not throw ConcurrentModificationException
- Slower in non-multi threading applications
No comments:
Post a Comment