Interface ArchiveStreamProvider
-
- All Known Implementing Classes:
ArchiveStreamFactory
public interface ArchiveStreamProviderCreates ArchiveArchiveInputStreams andArchiveOutputStreams.- Since:
- 1.13
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description <I extends ArchiveInputStream<? extends ArchiveEntry>>
IcreateArchiveInputStream(java.lang.String archiverName, java.io.InputStream inputStream, java.lang.String encoding)Creates an archive input stream from an archiver name and an input stream.<O extends ArchiveOutputStream<? extends ArchiveEntry>>
OcreateArchiveOutputStream(java.lang.String archiverName, java.io.OutputStream outputStream, java.lang.String encoding)Creates an archive output stream from an archiver name and an output stream.java.util.Set<java.lang.String>getInputStreamArchiveNames()Gets all the input stream archive names for this providerjava.util.Set<java.lang.String>getOutputStreamArchiveNames()Gets all the output stream archive names for this provider
-
-
-
Method Detail
-
createArchiveInputStream
<I extends ArchiveInputStream<? extends ArchiveEntry>> I createArchiveInputStream(java.lang.String archiverName, java.io.InputStream inputStream, java.lang.String encoding) throws ArchiveException
Creates an archive input stream from an archiver name and an input stream.- Type Parameters:
I- TheArchiveInputStreamtype.- Parameters:
archiverName- the archiver name, i.e. "ar", "arj", "zip", "tar", "jar", "cpio", "dump" or "7z"inputStream- the input streamencoding- encoding name or null for the default- Returns:
- the archive input stream
- Throws:
ArchiveException- if the archiver name is not knownStreamingNotSupportedException- if the format cannot be read from a streamjava.lang.IllegalArgumentException- if the archiver name or stream is null
-
createArchiveOutputStream
<O extends ArchiveOutputStream<? extends ArchiveEntry>> O createArchiveOutputStream(java.lang.String archiverName, java.io.OutputStream outputStream, java.lang.String encoding) throws ArchiveException
Creates an archive output stream from an archiver name and an output stream.- Type Parameters:
O- TheArchiveInputStreamtype.- Parameters:
archiverName- the archiver name, i.e. "ar", "zip", "tar", "jar" or "cpio"outputStream- the output streamencoding- encoding name or null for the default- Returns:
- the archive output stream
- Throws:
ArchiveException- if the archiver name is not knownStreamingNotSupportedException- if the format cannot be written to a streamjava.lang.IllegalArgumentException- if the archiver name or stream is null
-
getInputStreamArchiveNames
java.util.Set<java.lang.String> getInputStreamArchiveNames()
Gets all the input stream archive names for this provider- Returns:
- all the input archive names for this provider
-
getOutputStreamArchiveNames
java.util.Set<java.lang.String> getOutputStreamArchiveNames()
Gets all the output stream archive names for this provider- Returns:
- all the output archive names for this provider
-
-