|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.at4j.tar.TarExtractSpecification
public class TarExtractSpecification
This specification object contains configuration for an extraction operation
by the TarExtractor
.
When this object is instantiated, it contains the default extraction settings:
ExtractTarEntryExtractionStrategy
).
Constructor Summary | |
---|---|
TarExtractSpecification()
|
Method Summary | |
---|---|
TarEntryExtractionStrategy |
getEntryExtractionStrategy()
Get the strategy object used for extracting entries. |
Charset |
getFileNameCharset()
Get the charset used for decoding file names in the Tar file. |
Filter<? super TarEntryHeaderData> |
getFilter()
Get the filter that is used to decide which of the Tar entries to extract. |
OverwriteStrategy |
getOverwriteStrategy()
Are existing entities overwritten with entries from the archive? |
TarExtractSpecification |
setEntryExtractionStrategy(TarEntryExtractionStrategy strat)
Set the strategy object used for extracting entries. |
TarExtractSpecification |
setFileNameCharset(Charset cs)
Set the charset to use for decoding file names in the Tar file (and the names of other entry types as well). |
TarExtractSpecification |
setFilter(Filter<? super TarEntryHeaderData> f)
Set the filter to use to decide which entries to extract. |
TarExtractSpecification |
setOverwriteStrategy(OverwriteStrategy os)
If there already are an entity (file or directory) at the location where an entry should be extracted, should the old entity be overwritten? Should a warning message be printed? |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public TarExtractSpecification()
Method Detail |
---|
public TarExtractSpecification setFilter(Filter<? super TarEntryHeaderData> f)
null
to extract all entries.
All entries in the Tar file are evaluated against this filter. If it matches an entry but not its parent directory, the parent directory is extracted anyway.
f
- The filter that is used to decide which entries to extract. Any
ArchiveEntryFilter
works here.public Filter<? super TarEntryHeaderData> getFilter()
null
, all entries are extracted.
null
.public TarExtractSpecification setEntryExtractionStrategy(TarEntryExtractionStrategy strat)
strat
- The strategy object.public TarEntryExtractionStrategy getEntryExtractionStrategy()
public TarExtractSpecification setFileNameCharset(Charset cs)
cs
- The charset.public Charset getFileNameCharset()
public TarExtractSpecification setOverwriteStrategy(OverwriteStrategy os)
Non-empty directories cannot be overwritten. If the Tar extractor
attempts to do so, an TarFileParseException
is thrown.
os
- The strategy to use for overwriting entities.
this
public OverwriteStrategy getOverwriteStrategy()
setOverwriteStrategy(OverwriteStrategy)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |