Package jetbrains.buildServer.util.impl
Class CommonsCompressArchiveExtractorBase
- java.lang.Object
-
- jetbrains.buildServer.util.impl.CommonsCompressArchiveExtractorBase
-
- All Implemented Interfaces:
TeamCityExtension
,ArchiveExtractor
- Direct Known Subclasses:
StreamZipArchiveExtractor
,TarArchiveExtractor
public abstract class CommonsCompressArchiveExtractorBase extends Object implements ArchiveExtractor
Created by IntelliJ IDEA. User: Leonid.Shalupov Date: 13.03.2010 Time: 19:44:48
-
-
Constructor Summary
Constructors Constructor Description CommonsCompressArchiveExtractorBase()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract org.apache.commons.compress.archivers.ArchiveInputStream
createReader(File archive, InputStream archiveStream)
void
extractFiles(File archive, ArchiveFileSelector selector)
Extracts files from given archive filtered by file selectorMap<String,Long>
getEntitiesSize(File archive)
protected void
postProcessEntry(org.apache.commons.compress.archivers.ArchiveEntry entry, File file, File root)
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface jetbrains.buildServer.util.ArchiveExtractor
getEntitiesUnixPermissions, isSupported
-
-
-
-
Method Detail
-
createReader
protected abstract org.apache.commons.compress.archivers.ArchiveInputStream createReader(@NotNull File archive, @NotNull InputStream archiveStream) throws org.apache.commons.compress.archivers.ArchiveException, IOException
- Throws:
org.apache.commons.compress.archivers.ArchiveException
IOException
-
postProcessEntry
protected void postProcessEntry(@NotNull org.apache.commons.compress.archivers.ArchiveEntry entry, @NotNull File file, @Nullable File root)
-
getEntitiesSize
public Map<String,Long> getEntitiesSize(@NotNull File archive) throws IOException
- Specified by:
getEntitiesSize
in interfaceArchiveExtractor
- Parameters:
archive
- archive to be processed- Returns:
- map of entities name to uncompressed size on this entry, same names which are used in
ArchiveFileSelector
will be used as keys, -1 as size may be returned if size is unknown - Throws:
IOException
- Error occurred during extraction
-
extractFiles
public void extractFiles(@NotNull File archive, @NotNull ArchiveFileSelector selector) throws IOException
Description copied from interface:ArchiveExtractor
Extracts files from given archive filtered by file selector- Specified by:
extractFiles
in interfaceArchiveExtractor
- Parameters:
archive
- archive to be processedselector
- selector for files within the archive- Throws:
IOException
- Error occurred during extraction
-
-