gpt4 book ai didi

com.amse.ys.zip.ZipException.()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-13 11:30:17 25 4
gpt4 key购买 nike

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

ZipException.<init>介绍

暂无

代码示例

代码示例来源:origin: ydcx/KooReader

static Decompressor init(MyBufferedInputStream is, LocalFileHeader header) throws IOException {
  switch (header.CompressionMethod) {
    case 0:
      return new NoCompressionDecompressor(is, header);
    case 8:
      synchronized (ourDeflators) {
        if (!ourDeflators.isEmpty()) {
          DeflatingDecompressor decompressor = ourDeflators.poll();
          decompressor.reset(is, header); // 将压缩状态多大 解压多大等信息传入
          return decompressor;
        }
      }
      return new DeflatingDecompressor(is, header);
    default:
      throw new ZipException("Unsupported method of compression");
  }
}

代码示例来源:origin: Jiangzqts/EpubRead

static Decompressor init(MyBufferedInputStream is, LocalFileHeader header) throws IOException {
  switch (header.CompressionMethod) {
    case 0:
      return new NoCompressionDecompressor(is, header);
    case 8:
      synchronized (ourDeflators) {
        if (!ourDeflators.isEmpty()) {
          DeflatingDecompressor decompressor = ourDeflators.poll();
          decompressor.reset(is, header); // 将压缩状态多大 解压多大等信息传入
          return decompressor;
        }
      }
      return new DeflatingDecompressor(is, header);
    default:
      throw new ZipException("Unsupported method of compression");
  }
}

代码示例来源:origin: ydcx/KooReader

throw new ZipException("Entry " + entryName + " is not found");
  storeBaseStream(baseStream);
throw new ZipException("Entry " + entryName + " is not found");

代码示例来源:origin: Jiangzqts/EpubRead

throw new ZipException("Entry " + entryName + " is not found");
  storeBaseStream(baseStream);
throw new ZipException("Entry " + entryName + " is not found");

代码示例来源:origin: ydcx/KooReader

extraInfo.append(myInBuffer[myInBufferOffset + i]).append(",");
throw new ZipException("Cannot inflate zip-compressed block, code = " + result + ";extra info = " + extraInfo);
throw new ZipException("Invalid inflating result, code = " + result + "; buffer length = " + myInBufferLength);

代码示例来源:origin: Jiangzqts/EpubRead

extraInfo.append(myInBuffer[myInBufferOffset + i]).append(",");
throw new ZipException("Cannot inflate zip-compressed block, code = " + result + ";extra info = " + extraInfo);
throw new ZipException("Invalid inflating result, code = " + result + "; buffer length = " + myInBufferLength);

代码示例来源:origin: ydcx/KooReader

int read2Bytes() throws IOException {
  LogUtil.i1("amseys");
  int low = read();
  int high = read();
  if (high < 0) {
    throw new ZipException("unexpected end of file at position " + offset());
  }
  return (high << 8) + low;
}

代码示例来源:origin: Jiangzqts/EpubRead

int read2Bytes() throws IOException {
  LogUtil.i1("amseys");
  int low = read();
  int high = read();
  if (high < 0) {
    throw new ZipException("unexpected end of file at position " + offset());
  }
  return (high << 8) + low;
}

代码示例来源:origin: ydcx/KooReader

int read4Bytes() throws IOException {
  int firstByte = read();
  int secondByte = read();
  int thirdByte = read();
  int fourthByte = read();
  if (fourthByte < 0) {
    throw new ZipException("unexpected end of file at position " + offset());
  }
  return (fourthByte << 24) + (thirdByte << 16) + (secondByte << 8) + firstByte;
}

代码示例来源:origin: Jiangzqts/EpubRead

int read4Bytes() throws IOException {
  int firstByte = read();
  int secondByte = read();
  int thirdByte = read();
  int fourthByte = read();
  if (fourthByte < 0) {
    throw new ZipException("unexpected end of file at position " + offset());
  }
  return (fourthByte << 24) + (thirdByte << 16) + (secondByte << 8) + firstByte;
}

代码示例来源:origin: Jiangzqts/EpubRead

void reset(MyBufferedInputStream inputStream, LocalFileHeader header) throws IOException {
  if (myInflatorId != -1) {
    endInflating(myInflatorId);
    myInflatorId = -1;
  }
  myStream = inputStream;
  myCompressedAvailable = header.CompressedSize;
  if (myCompressedAvailable <= 0) {
    myCompressedAvailable = Integer.MAX_VALUE;
  }
  myAvailable = header.UncompressedSize;
  if (myAvailable <= 0) {
    myAvailable = Integer.MAX_VALUE;
  }
  LogUtil.i21("compressed:"+myCompressedAvailable);
  LogUtil.i21("compressed:"+myAvailable);
  myInBufferOffset = IN_BUFFER_SIZE;
  myInBufferLength = 0;
  myOutBufferOffset = OUT_BUFFER_SIZE;
  myOutBufferLength = 0;
  myInflatorId = startInflating();
  if (myInflatorId == -1) {
    throw new ZipException("cannot start inflating");
  }
}

代码示例来源:origin: ydcx/KooReader

void reset(MyBufferedInputStream inputStream, LocalFileHeader header) throws IOException {
  if (myInflatorId != -1) {
    endInflating(myInflatorId);
    myInflatorId = -1;
  }
  myStream = inputStream;
  myCompressedAvailable = header.CompressedSize;
  if (myCompressedAvailable <= 0) {
    myCompressedAvailable = Integer.MAX_VALUE;
  }
  myAvailable = header.UncompressedSize;
  if (myAvailable <= 0) {
    myAvailable = Integer.MAX_VALUE;
  }
  LogUtil.i21("compressed:"+myCompressedAvailable);
  LogUtil.i21("compressed:"+myAvailable);
  myInBufferOffset = IN_BUFFER_SIZE;
  myInBufferLength = 0;
  myOutBufferOffset = OUT_BUFFER_SIZE;
  myOutBufferLength = 0;
  myInflatorId = startInflating();
  if (myInflatorId == -1) {
    throw new ZipException("cannot start inflating");
  }
}

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