public interface UnArchiver
Modifier and Type | Method and Description |
---|---|
void |
extract()
Extract the archive.
|
void |
extract(String path,
File outputDirectory)
Take a path into the archive and extract it to the specified directory.
|
File |
getDestDirectory() |
File |
getDestFile() |
org.codehaus.plexus.components.io.filemappers.FileMapper[] |
getFileMappers()
Get chain of components which rewrite the target path of each unpacked file.
|
org.codehaus.plexus.components.io.fileselectors.FileSelector[] |
getFileSelectors()
Returns a set of
FileSelector instances, which may be used to select the files to extract from the
archive. |
File |
getSourceFile() |
boolean |
isIgnorePermissions() |
boolean |
isOverwrite()
Gets a flag indicating destination files are always overwritten.
|
boolean |
isUseJvmChmod()
Deprecated.
this setting is now ignored. The jvm is always used.
|
void |
setDestDirectory(File destDirectory) |
void |
setDestFile(File destFile) |
void |
setFileMappers(org.codehaus.plexus.components.io.filemappers.FileMapper[] fileMappers)
Sets chain of components to be used for rewriting target path of each unpacked file.
|
void |
setFileSelectors(org.codehaus.plexus.components.io.fileselectors.FileSelector[] selectors)
Sets a set of
FileSelector instances, which may be used to select the files to extract from the archive. |
void |
setIgnorePermissions(boolean ignorePermissions) |
void |
setOverwrite(boolean b)
Should we overwrite files in dest, even if they are newer than the corresponding entries in the archive?
|
void |
setSourceFile(File sourceFile) |
void |
setUseJvmChmod(boolean useJvmChmod)
Deprecated.
this setting is now ignored. The jvm is always used.
|
static final String ROLE
void extract() throws ArchiverException
ArchiverException
void extract(String path, File outputDirectory) throws ArchiverException
path
- Path inside the archive to be extracted.outputDirectory
- Directory to extract to.ArchiverException
File getDestDirectory()
void setDestDirectory(File destDirectory)
File getDestFile()
void setDestFile(File destFile)
File getSourceFile()
void setSourceFile(File sourceFile)
boolean isOverwrite()
true
, if destination files are overwritten, even if they are newer than the corresponding entry
in the archive.void setOverwrite(boolean b)
org.codehaus.plexus.components.io.filemappers.FileMapper[] getFileMappers()
FileMapper
s to be used for rewriting each target path, or null
if no rewriting shall happen.void setFileMappers(org.codehaus.plexus.components.io.filemappers.FileMapper[] fileMappers)
fileMappers
- FileMapper
to be used for rewriting each target path, or null
if no
rewriting shall happen.void setFileSelectors(org.codehaus.plexus.components.io.fileselectors.FileSelector[] selectors)
FileSelector
instances, which may be used to select the files to extract from the archive.
If file selectors are present, then a file is only extracted, if it is confirmed by all file selectors.org.codehaus.plexus.components.io.fileselectors.FileSelector[] getFileSelectors()
FileSelector
instances, which may be used to select the files to extract from the
archive. If file selectors are present, then a file is only extracted, if it is confirmed by all file selectors.@Deprecated void setUseJvmChmod(boolean useJvmChmod)
useJvmChmod
- @Deprecated boolean isUseJvmChmod()
boolean isIgnorePermissions()
void setIgnorePermissions(boolean ignorePermissions)
Copyright © 2001–2022 Codehaus Plexus. All rights reserved.