Hi All,
I'm working on a project where I need to read about a dozen files within a zipped folder, of which one is a text file, and the rest are image files.
I basically need to editi the text file within the zipped folder and forward the entire zipped folder and contents to another dirrectory/folder location.
Here's the steps I've thought out so far...
1.) I need to save the original zipped folder and its files off incase I need to revert.
So, first I need to create a temporary folder and place a copy of the zipped file there.
In doing this: reading in all the files and writing them out to the temporary folder.
2.) read the text file in the new temporary folder and rewrite it there as well.
3.) read in all the files in the temporary folder and rewrite them as copressed in a zipped folder within the temporary folder.
4.) move the new zipped folder and its contents to the destination path using IO methode "renameTo()".
5.) remove/delete the tempoorary folder.
My question is... Is this the most efficient way to do this using
Java?
Please advice...