你能帮我找到一种方法来强制库正确关闭文件,并允许其他进程进一步修改它们。目前,当文件由下面的代码片段处理时,它们由应用程序保存,不能修改。
//input represents FileObject zip file
FileObject zip = fsManager.createFileSystem(input); //auxiliary variable used for extracting zip file content (input)
tmpDir.copyFrom(zip, new AllFileSelector());
zip.close(); // it's closed properly
// input.close() or ((AbstractFileSystem)input.getFileSystem()).close() doesn't help to release the lock