Вот и все. У меня есть текстовый файл, и мне нужно переместить его в (существующий) Zip-файл в заданном каталоге.
File file = new File("C:\\afolder\\test.txt");
File dir = new File(directoryToGo+"existingzipfile.zip");
boolean success = file.renameTo(new File(dir, file.getName()));
Но это не работает. Есть ли способ переместить файл в существующий Zip-файл? Спасибо.
java.util.zip
, в частностиZipFile
. См. этот ответ. - person pb2q   schedule 10.08.2012