• Post Reply Bookmark Topic Watch Topic
  • New Topic

How to implemnt dupplicate key map...  RSS feed

 
dumani jayasinghe
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please can any one guide me to implement map with duplicate key?
 
Joseph Mokenela
Ranch Hand
Posts: 71
Eclipse IDE Hibernate Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I would suggest you check the following link.

http://stackoverflow.com/questions/1062960/map-implementation-with-duplicate-keys

Hope that helps!
 
Campbell Ritchie
Marshal
Posts: 56220
171
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That is a contradiction in terms. A map represents a function, and a function cannot have duplicate results from one input.
It is easy to have duplicate values. . . . will work, but this wont't:you will ony ever get Bunkhouse Porch out of that Map.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!