File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Beginning Java and the fly likes HashMap Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "HashMap" Watch "HashMap" New topic
Author

HashMap

raghuram bikkani
Greenhorn

Joined: Jan 18, 2006
Posts: 16
How can u implement HashMap if u don't have a HashMap?
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60057
    
  65

HashMap is not an interface, so you cannot implement it. Do you mean java.util.Map?


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Layne Lund
Ranch Hand

Joined: Dec 06, 2001
Posts: 3061
I don't understand your question. HashMap is a concrete class, so you can create objects from it:

Does this help?

Layne


Java API Documentation
The Java Tutorial
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14687
    
  16

I guess that he wants to mimic the behavious of HashMap.
By 'implement' he means 'create'.


[My Blog]
All roads lead to JavaRanch
Jesper de Jong
Java Cowboy
Saloon Keeper

Joined: Aug 16, 2005
Posts: 13875
    
  10

Originally posted by raghuram bikkani:
How can u implement HashMap if u don't have a HashMap?

What do you mean? If you have a REALLY OLD version of Java that doesn't have HashMap, you can use java.util.Hashtable.


Java Beginners FAQ - JavaRanch SCJP FAQ - The Java Tutorial - Java SE 7 API documentation
Scala Notes - My blog about Scala
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: HashMap
 
Similar Threads
WeakHashMap error?
How to get Hashmap's value in jsp?
Static method
switch on String
WA #1.....word association