Possible Duplicate:
Java - HashMap vs Map objects
I want to know the difference between HashMap and Map in java..??
Possible Duplicate:
Java - HashMap vs Map objects
I want to know the difference between HashMap and Map in java..??
Map is an interface, i.e. an abstract "thing" that defines how something can be used. HashMap is an implementation of that interface.
Map is an interface; HashMap is a particular implementation of that interface.
HashMap uses a collection of hashed key values to do its lookup. TreeMap will use a red-black tree as its underlying data store.
Map is an interface in Java. And HashMap is an implementation of that interface (i.e. provides all of the methods specified in the interface).
HashMap is an implementation of Map. Map is just an interface for any type of map.