本文整理了Java中org.zeroturnaround.zip.ZipUtil.removeEntry()
方法的一些代码示例,展示了ZipUtil.removeEntry()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ZipUtil.removeEntry()
方法的具体详情如下:
包路径:org.zeroturnaround.zip.ZipUtil
类名称:ZipUtil
方法名:removeEntry
[英]Changes an existing ZIP file: removes entry with a given path.
[中]更改现有ZIP文件:删除具有给定路径的条目。
代码示例来源:origin: zeroturnaround/zt-zip
public boolean act(File tmpFile) {
removeEntry(zip, path, tmpFile);
return true;
}
});
代码示例来源:origin: jphp-group/jphp
@Signature
public void remove(Environment env, Memory path) {
if (path.isTraversable()) {
ForeachIterator iterator = path.getNewIterator(env);
List<String> paths = new ArrayList<>();
while (iterator.next()) {
String value = iterator.getValue().toString();
paths.add(value);
}
ZipUtil.removeEntries(zipFile, paths.toArray(new String[paths.size()]));
} else {
ZipUtil.removeEntry(zipFile, path.toString());
}
}
代码示例来源:origin: org.zeroturnaround/zt-zip
public boolean act(File tmpFile) {
removeEntry(zip, path, tmpFile);
return true;
}
});
代码示例来源:origin: org.hswebframework/hsweb-expands-compress
public void remove(String entryName) throws IOException {
ZipUtil.removeEntry(zipFile, entryName);
}
代码示例来源:origin: hs-web/hsweb-expands
public void remove(String entryName) throws IOException {
ZipUtil.removeEntry(zipFile, entryName);
}
代码示例来源:origin: com.microsoft.azure/azure-maven-plugin-lib
protected File getZipFile() {
final File zipFile = new File(stagingDirectoryPath + ".zip");
final File stagingDirectory = new File(stagingDirectoryPath);
ZipUtil.pack(stagingDirectory, zipFile);
ZipUtil.removeEntry(zipFile, LOCAL_SETTINGS_FILE);
return zipFile;
}
}
代码示例来源:origin: Microsoft/azure-maven-plugins
protected File getZipFile() {
final File zipFile = new File(stagingDirectoryPath + ".zip");
final File stagingDirectory = new File(stagingDirectoryPath);
ZipUtil.pack(stagingDirectory, zipFile);
ZipUtil.removeEntry(zipFile, LOCAL_SETTINGS_FILE);
return zipFile;
}
}
代码示例来源:origin: Microsoft/azure-maven-plugins
protected File createZipPackage() throws Exception {
logInfo("");
logInfo(CREATE_ZIP_START);
final File stageDirectory = new File(stagingDirectoryPath);
final File zipPackage = new File(stagingDirectoryPath.concat(ZIP_EXT));
if (!stageDirectory.exists()) {
logError(STAGE_DIR_NOT_FOUND);
throw new Exception(STAGE_DIR_NOT_FOUND);
}
ZipUtil.pack(stageDirectory, zipPackage);
logDebug(REMOVE_LOCAL_SETTINGS);
ZipUtil.removeEntry(zipPackage, LOCAL_SETTINGS_FILE);
logInfo(CREATE_ZIP_DONE + stagingDirectoryPath.concat(ZIP_EXT));
return zipPackage;
}
内容来源于网络,如有侵权,请联系作者删除!