Class ZipOnDemandInputStream

  • All Implemented Interfaces:
    java.io.Closeable, java.lang.AutoCloseable

    class ZipOnDemandInputStream
    extends AbstractOnDemandInputStream<java.util.zip.ZipOutputStream>
    ZIP on demand input stream.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected void closeEntry​(java.util.zip.ZipOutputStream outputStream)
      Closes the current entry context for the specified OutputStream.
      protected java.util.zip.ZipOutputStream createOutputStream​(java.io.OutputStream outputStream)
      Creates the real OutputStream to which we'll write, wrapping the provided target.
      protected void putNextEntry​(java.util.zip.ZipOutputStream outputStream, java.lang.String context)
      Writes the next entry (demarcates a new file/folder is to be written).
      • Methods inherited from class java.io.InputStream

        available, close, mark, markSupported, read, read, reset, skip
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ZipOnDemandInputStream

        ZipOnDemandInputStream​(Archive<?> archive)
        Creates stream directly from archive.
        Parameters:
        archive -
    • Method Detail

      • createOutputStream

        protected java.util.zip.ZipOutputStream createOutputStream​(java.io.OutputStream outputStream)
        Description copied from class: AbstractOnDemandInputStream
        Creates the real OutputStream to which we'll write, wrapping the provided target.
        Specified by:
        createOutputStream in class AbstractOnDemandInputStream<java.util.zip.ZipOutputStream>
        Returns:
      • closeEntry

        protected void closeEntry​(java.util.zip.ZipOutputStream outputStream)
                           throws java.io.IOException
        Description copied from class: AbstractOnDemandInputStream
        Closes the current entry context for the specified OutputStream.
        Specified by:
        closeEntry in class AbstractOnDemandInputStream<java.util.zip.ZipOutputStream>
        Throws:
        java.io.IOException
      • putNextEntry

        protected void putNextEntry​(java.util.zip.ZipOutputStream outputStream,
                                    java.lang.String context)
                             throws java.io.IOException
        Description copied from class: AbstractOnDemandInputStream
        Writes the next entry (demarcates a new file/folder is to be written).
        Specified by:
        putNextEntry in class AbstractOnDemandInputStream<java.util.zip.ZipOutputStream>
        Throws:
        java.io.IOException - If an error occurred writing the entry