Results 1 to 3 of 3
- 08-11-2010, 02:40 PM #1Member
- Join Date
- Aug 2010
- Rep Power
Saving the contents of a variable to disk
I am writing a program that is very computation intensive. I am taking a large number of images, analysing them, and saving the results to an array. This step takes a very long amount of time, especially for large images, so it would be good if there is some way for me to save this array to disk, so I can just reload the variable the next time I run it, instead of starting from scratch.
I can do this fine with integer arrays, as I just write the numbers into a txt file and reload the next time. But I also have a File array, and I don't know how to save this one to disk. Any help? :(
- 08-11-2010, 08:56 PM #2
You cannot write an object array to anything. However, consider providing a unique piece of data (filename is the most obvious--and short filenames have no spaces, you know, PROGRA~1 and all that, so you can still tokenize from spaces), and saving that to the file instead.
- 08-11-2010, 10:37 PM #3
- By sidd0123 in forum New To JavaReplies: 3Last Post: 06-06-2010, 02:02 AM
- By johnvarg in forum AWT / SwingReplies: 1Last Post: 02-23-2010, 10:48 AM
- By gth05 in forum New To JavaReplies: 3Last Post: 12-03-2009, 11:05 PM
- By Java Tip in forum Java TipReplies: 0Last Post: 02-05-2008, 10:07 AM