Пример #1
0
  public ZipEntryInputStream(BinaryInput in, long position) throws IOException {
    super(Env.getInstance());

    _in = in;
    _position = position;

    in.setPosition(_position);

    ZipInputStream zipInputStream = new ZipInputStream(in.getInputStream());

    ZipEntry curEntry = zipInputStream.getNextEntry();

    if (curEntry == null)
      throw new IOException(L.l("ZipEntry at position {0} not found", _position));

    init(new ReadStream(new VfsStream(zipInputStream, null)));
  }
Пример #2
0
 /** Opens a copy. */
 public BinaryInput openCopy() throws IOException {
   return new ZipEntryInputStream(_in.openCopy(), _position);
 }