9
What are the differences between HashMap
and Hashtable
in Java?
Which is more efficient?
9
What are the differences between HashMap
and Hashtable
in Java?
Which is more efficient?
12
containsValue()
and containsKey()
AbstractMap
contains()
Dictionary
I withdrew the information mainly of that response in the OS.
Browser other questions tagged java hashmap collection
You are not signed in. Login or sign up in order to post.
Summarizing in a row: The Hashtable is synchronized (thread-safe). The Hashmap, no.
– Resende
Consequently, if it is a situation without competition, in which either use one or the other, the non-synchronized version (Hashmap) will be more efficient.
– Piovezan