Class ZipArchiveEntryRequest
java.lang.Object
org.apache.commons.compress.archivers.zip.ZipArchiveEntryRequest
A Thread-safe representation of a ZipArchiveEntry that is used to add entries to parallel archives.
- Since:
- 1.10
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final int
private final InputStreamSupplier
private final ZipArchiveEntry
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprivate
ZipArchiveEntryRequest
(ZipArchiveEntry zipArchiveEntry, InputStreamSupplier payloadSupplier) -
Method Summary
Modifier and TypeMethodDescriptionstatic ZipArchiveEntryRequest
createZipArchiveEntryRequest
(ZipArchiveEntry zipArchiveEntry, InputStreamSupplier payloadSupplier) Create a ZipArchiveEntryRequestint
The compression method to useThe payload that will be added to this zip entry(package private) ZipArchiveEntry
Gets the underlying entry.
-
Field Details
-
zipArchiveEntry
-
payloadSupplier
-
method
private final int method
-
-
Constructor Details
-
ZipArchiveEntryRequest
private ZipArchiveEntryRequest(ZipArchiveEntry zipArchiveEntry, InputStreamSupplier payloadSupplier)
-
-
Method Details
-
createZipArchiveEntryRequest
public static ZipArchiveEntryRequest createZipArchiveEntryRequest(ZipArchiveEntry zipArchiveEntry, InputStreamSupplier payloadSupplier) Create a ZipArchiveEntryRequest- Parameters:
zipArchiveEntry
- The entry to usepayloadSupplier
- The payload that will be added to the zip entry.- Returns:
- The newly created request
-
getPayloadStream
The payload that will be added to this zip entry- Returns:
- The input stream.
-
getMethod
public int getMethod()The compression method to use- Returns:
- The compression method to use
-
getZipArchiveEntry
ZipArchiveEntry getZipArchiveEntry()Gets the underlying entry. Do not use this methods from threads that did not create the instance itself !- Returns:
- the zipArchiveEntry that is basis for this request
-