gpt4 book ai didi

net.lingala.zip4j.model.ZipParameters.getCompressionLevel()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-15 16:44:40 28 4
gpt4 key购买 nike

本文整理了Java中net.lingala.zip4j.model.ZipParameters.getCompressionLevel()方法的一些代码示例,展示了ZipParameters.getCompressionLevel()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ZipParameters.getCompressionLevel()方法的具体详情如下:
包路径:net.lingala.zip4j.model.ZipParameters
类名称:ZipParameters
方法名:getCompressionLevel

ZipParameters.getCompressionLevel介绍

暂无

代码示例

代码示例来源:origin: net.lingala.zip4j/zip4j

public void putNextEntry(File file, ZipParameters zipParameters)
    throws ZipException {
  super.putNextEntry(file, zipParameters);
  if (zipParameters.getCompressionMethod() == Zip4jConstants.COMP_DEFLATE) {
    deflater.reset();
    if ((zipParameters.getCompressionLevel() < 0 || zipParameters
        .getCompressionLevel() > 9)
        && zipParameters.getCompressionLevel() != -1) {
      throw new ZipException(
          "invalid compression level for deflater. compression level should be in the range of 0-9");
    }
    deflater.setLevel(zipParameters.getCompressionLevel());
  }
}

代码示例来源:origin: com.github.axet/zip4j

public void putNextEntry(NativeStorage file, ZipParameters zipParameters)
    throws ZipException {
  super.putNextEntry(file, zipParameters);
  if (zipParameters.getCompressionMethod() == Zip4jConstants.COMP_DEFLATE) {
    deflater.reset();
    if ((zipParameters.getCompressionLevel() < 0 || zipParameters
        .getCompressionLevel() > 9)
        && zipParameters.getCompressionLevel() != -1) {
      throw new ZipException(
          "invalid compression level for deflater. compression level should be in the range of 0-9");
    }
    deflater.setLevel(zipParameters.getCompressionLevel());
  }
}

代码示例来源:origin: net.lingala.zip4j/zip4j

if (parameters.getCompressionLevel() < 0 && parameters.getCompressionLevel() > 9) {
  throw new ZipException("invalid compression level. compression level dor deflate should be in the range of 0-9");

代码示例来源:origin: com.github.axet/zip4j

if (parameters.getCompressionLevel() < 0 && parameters.getCompressionLevel() > 9) {
  throw new ZipException("invalid compression level. compression level dor deflate should be in the range of 0-9");

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com