Package eu.simuline.util
Class JavaPath.ZipEntryWrapper
- java.lang.Object
-
- eu.simuline.util.JavaPath.ZipEntryWrapper
-
- All Implemented Interfaces:
JavaPath.FileWrapper
- Enclosing class:
- JavaPath
static class JavaPath.ZipEntryWrapper extends Object implements JavaPath.FileWrapper
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) classJavaPath.ZipEntryWrapper.WrappedInputStreamA filter input stream closingzipFilewhen closing the stream.
-
Constructor Summary
Constructors Constructor Description ZipEntryWrapper(ZipFile zipFile, ZipEntry entry)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleancoversZip()Returns whether the wrapped file is within a zip-archive.FilegetFile()Returns the file wrapped.InputStreamgetInputStream()Returns an input stream for the file wrapped.
-
-
-
Method Detail
-
coversZip
public boolean coversZip()
Description copied from interface:JavaPath.FileWrapperReturns whether the wrapped file is within a zip-archive. If this is the case, the file wrapped was created newly.- Specified by:
coversZipin interfaceJavaPath.FileWrapper- Returns:
- a
booleanvalue signifying whether the wrapped file is within a zip-archive.
-
getFile
public File getFile() throws IOException
Description copied from interface:JavaPath.FileWrapperReturns the file wrapped. If the wrapped file is within a zip-archive, it was created newly by thisFileWrapper.- Specified by:
getFilein interfaceJavaPath.FileWrapper- Returns:
- the
Filewrapped. - Throws:
IOException- if an error occurs
-
getInputStream
public InputStream getInputStream() throws IOException
Description copied from interface:JavaPath.FileWrapperReturns an input stream for the file wrapped.- Specified by:
getInputStreamin interfaceJavaPath.FileWrapper- Returns:
- the
InputStreamof the file wrapped. - Throws:
IOException- if an error occurs
-
-