Class ZipOnDemandInputStream
java.lang.Object
java.io.InputStream
org.jboss.shrinkwrap.impl.base.exporter.AbstractOnDemandInputStream<ZipOutputStream>
org.jboss.shrinkwrap.impl.base.exporter.zip.ZipOnDemandInputStream
- All Implemented Interfaces:
Closeable
,AutoCloseable
ZIP on demand input stream.
-
Field Summary
Fields inherited from class org.jboss.shrinkwrap.impl.base.exporter.AbstractOnDemandInputStream
outputStream
-
Constructor Summary
ConstructorsConstructorDescriptionZipOnDemandInputStream
(Archive<?> archive) Creates stream directly from archive. -
Method Summary
Modifier and TypeMethodDescriptionprotected void
closeEntry
(ZipOutputStream outputStream) Closes the current entry context for the specifiedOutputStream
.protected ZipOutputStream
createOutputStream
(OutputStream outputStream) Creates the realOutputStream
to which we'll write, wrapping the provided target.protected void
putNextEntry
(ZipOutputStream outputStream, String context) Writes the next entry (demarcates a new file/folder is to be written).Methods inherited from class org.jboss.shrinkwrap.impl.base.exporter.AbstractOnDemandInputStream
read
Methods inherited from class java.io.InputStream
available, close, mark, markSupported, read, read, reset, skip
-
Constructor Details
-
ZipOnDemandInputStream
ZipOnDemandInputStream(Archive<?> archive) Creates stream directly from archive.- Parameters:
archive
-
-
-
Method Details
-
createOutputStream
Description copied from class:AbstractOnDemandInputStream
Creates the realOutputStream
to which we'll write, wrapping the provided target.- Specified by:
createOutputStream
in classAbstractOnDemandInputStream<ZipOutputStream>
- Parameters:
outputStream
-- Returns:
-
closeEntry
Description copied from class:AbstractOnDemandInputStream
Closes the current entry context for the specifiedOutputStream
.- Specified by:
closeEntry
in classAbstractOnDemandInputStream<ZipOutputStream>
- Parameters:
outputStream
-- Throws:
IOException
-
putNextEntry
Description copied from class:AbstractOnDemandInputStream
Writes the next entry (demarcates a new file/folder is to be written).- Specified by:
putNextEntry
in classAbstractOnDemandInputStream<ZipOutputStream>
- Parameters:
outputStream
-context
-- Throws:
IOException
- If an error occurred writing the entry
-