Knopflerfish OSGi 1.3.3

org.knopflerfish.util.cm
Class ZipFileInputStream

java.lang.Object
  extended byjava.io.InputStream
      extended byorg.knopflerfish.util.cm.ZipFileInputStream

public class ZipFileInputStream
extends java.io.InputStream

Input stream for a zip file entry that closes the zip file when closed.


Constructor Summary
ZipFileInputStream(java.util.zip.ZipFile zf, java.io.InputStream in)
           
 
Method Summary
 int available()
           
 void close()
           
static java.io.InputStream getInputStream(java.net.URL url)
          This open method returns an input stream that works around the problem that closing the input stream returned by URL.openStream() on a jar:file:xxx!/sss URL does not close the underlaying jar file.
 void mark(int readlimit)
           
 boolean markSupported()
           
 int read()
           
 int read(byte[] b)
           
 int read(byte[] b, int off, int len)
           
 void reset()
           
 long skip(long n)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ZipFileInputStream

public ZipFileInputStream(java.util.zip.ZipFile zf,
                          java.io.InputStream in)
Method Detail

getInputStream

public static java.io.InputStream getInputStream(java.net.URL url)
                                          throws java.io.IOException
This open method returns an input stream that works around the problem that closing the input stream returned by URL.openStream() on a jar:file:xxx!/sss URL does not close the underlaying jar file.

Throws:
java.io.IOException

read

public int read()
         throws java.io.IOException
Throws:
java.io.IOException

read

public int read(byte[] b)
         throws java.io.IOException
Throws:
java.io.IOException

read

public int read(byte[] b,
                int off,
                int len)
         throws java.io.IOException
Throws:
java.io.IOException

skip

public long skip(long n)
          throws java.io.IOException
Throws:
java.io.IOException

available

public int available()
              throws java.io.IOException
Throws:
java.io.IOException

close

public void close()
           throws java.io.IOException
Throws:
java.io.IOException

mark

public void mark(int readlimit)

reset

public void reset()
           throws java.io.IOException
Throws:
java.io.IOException

markSupported

public boolean markSupported()

Knopflerfish OSGi 1.3.3