|
-
June 8th, 2005, 03:40 PM
#1
memory problem
i am writing a program which is working on a 50MB file i am using hashmaps to store the words in the text file and the count as value and i am using some arrayLIsts having hashmap as values.and now the program gives me error
Exception in thread "main" java.lang.OutOfMemoryError
i tried using the command
java -Xms32m -Xmx128m filename
it speed up the process a bit bit still the error is there
can you please tell me if there is any other command which i can use to get rid of this probelm .i understand it due to makinga lot of objects but now i am finding it hard to chg the structure of my program.
if you think its due to a lot of hashmaps ,if i make a class and make the objects and put in the vector and use that verctor as value of arraylist ..will it be better memory wise?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|