Class ZipArchiveWrapper
java.lang.Object
org.ctan.site.services.upload.util.archive.ZipArchiveWrapper
- All Implemented Interfaces:
Archive
The class
Archive
contains the wrapper for a ZIP archive.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
The classZipEntryWrapper
contains the wrapper for an entry.Nested classes/interfaces inherited from interface org.ctan.site.services.upload.util.archive.Archive
Archive.Entry
-
Constructor Summary
ConstructorsConstructorDescriptionZipArchiveWrapper
(String name, @NonNull InputStream in) This is the constructor forZipArchiveWrapper
. -
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
The methodclose
provides means to close the stream.void
The methodcloseEntry
provides means to close the current entry.getName()
The methodgetName
provides means to retrieve the file name.The methodgetNextEntry
provides means to move to the next entry.The methodgetStream
provides means to get the InputStream for the current entry.
-
Constructor Details
-
ZipArchiveWrapper
public ZipArchiveWrapper(String name, @NonNull @NonNull InputStream in) throws FileNotFoundException This is the constructor forZipArchiveWrapper
.- Parameters:
name
- the file namein
- the wrapped input stream- Throws:
FileNotFoundException
- in case of an I/O error
-
-
Method Details
-
close
The methodclose
provides means to close the stream.- Specified by:
close
in interfaceArchive
- Throws:
IOException
- in case of an I/O error- See Also:
-
closeEntry
The methodcloseEntry
provides means to close the current entry.- Specified by:
closeEntry
in interfaceArchive
- Throws:
IOException
- in case of an I/O error- See Also:
-
getName
The methodgetName
provides means to retrieve the file name. -
getNextEntry
The methodgetNextEntry
provides means to move to the next entry.- Specified by:
getNextEntry
in interfaceArchive
- Returns:
- the next entry
- Throws:
IOException
- in case of an I/O error- See Also:
-
getStream
The methodgetStream
provides means to get the InputStream for the current entry.
-