aspose file tools*
The moose likes Threads and Synchronization and the fly likes what does it mean that hashtable is synchronized and hashmaps are not? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Threads and Synchronization
Bookmark "what does it mean that hashtable is synchronized and hashmaps are not?" Watch "what does it mean that hashtable is synchronized and hashmaps are not?" New topic
Author

what does it mean that hashtable is synchronized and hashmaps are not?

Raghda Ismail
Greenhorn

Joined: Feb 22, 2009
Posts: 23
hi everybody ,
please i need to know what does it mean that hash table is synchronized and hash maps are not?

Thanks
Henry Wong
author
Sheriff

Joined: Sep 28, 2004
Posts: 18108
    
  39

Raghda Ismail wrote:please i need to know what does it mean that hash table is synchronized and hash maps are not?


It just means that the methods of the Hashtable class are declared as synchronized, while the methods of the HashMap class are not. As for what that means, you can start with the Sun tutorial on threads...

http://java.sun.com/docs/books/tutorial/essential/concurrency/

Henry


Books: Java Threads, 3rd Edition, Jini in a Nutshell, and Java Gems (contributor)
Raghda Ismail
Greenhorn

Joined: Feb 22, 2009
Posts: 23
thanks Henry
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: what does it mean that hashtable is synchronized and hashmaps are not?
 
Similar Threads
String Builder Class
Hash Table - Sychronization
dynamic polymorphism in java
what is load factor of hashset ???
Need help in understanding the internal working of HashMap and HashTable.