how copy the hashmap object into arraylist at java program?

Answer Posted / fellow java novice

/* HashMap hm; assume hash map has array list objects in it


ArrayList al = (ArrayList) hm.get("name by which arraylist
sits in the hashmap");

/* the crux of the matter is the user of 'get' to access
from hashmap

Is This Answer Correct ?    0 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can we override private method?

785


Explain the inheritance?

750


Is null a keyword in java?

726


What is the relationship between clipping and repainting under awt?

828


Is age a discrete variable?

713


Difference between start() and run() method of thread class?

795


What is null statement?

747


What are the restrictions imposed by a Security Manager on Applets?.

2287


Why is a string immutable?

744


What is the exact difference in between unicast and multicast object? Where we will use?

766


What the difference is between execute, execute Query, execute Update?

564


What are the types of arrays in java?

802


What are memory tables?

806


What is function and its uses?

774


What is the symbol for line break?

826