public abstract class ArchiveFileSet extends FileSet
Modifier and Type | Field and Description |
---|---|
static int |
DEFAULT_DIR_MODE
Default value for the dirmode attribute.
|
static int |
DEFAULT_FILE_MODE
Default value for the filemode attribute.
|
description, location, project
Modifier | Constructor and Description |
---|---|
|
ArchiveFileSet()
Constructor for ArchiveFileSet
|
protected |
ArchiveFileSet(ArchiveFileSet fileset)
Constructor using a archive fileset arguement.
|
protected |
ArchiveFileSet(FileSet fileset)
Constructor using a fileset arguement.
|
Modifier and Type | Method and Description |
---|---|
void |
addConfigured(ResourceCollection a)
Set the source Archive file for the archivefileset.
|
java.lang.Object |
clone()
Return a ArchiveFileSet that has the same properties
as this one.
|
protected void |
configureFileSet(ArchiveFileSet zfs)
A ArchiveFileset accepts another ArchiveFileSet or a FileSet as reference
FileSets are often used by the war task for the lib attribute
|
DirectoryScanner |
getDirectoryScanner(Project p)
Return the DirectoryScanner associated with this FileSet.
|
int |
getDirMode()
Deprecated.
since 1.7.
|
int |
getDirMode(Project p)
Get the dir mode of the archive fileset
|
int |
getFileMode()
Deprecated.
since 1.7.
|
int |
getFileMode(Project p)
Get the mode of the archive fileset
|
java.lang.String |
getFullpath()
Deprecated.
since 1.7.
|
java.lang.String |
getFullpath(Project p)
Return the full pathname of the single entry in this fileset.
|
java.lang.String |
getPrefix()
Deprecated.
since 1.7.
|
java.lang.String |
getPrefix(Project p)
Return the prefix prepended to entries in the archive file.
|
java.io.File |
getSrc()
Get the archive file from which entries will be extracted.
|
java.io.File |
getSrc(Project p)
Get the archive from which entries will be extracted.
|
boolean |
hasDirModeBeenSet()
Whether the user has specified the mode explicitly.
|
boolean |
hasFileModeBeenSet()
Whether the user has specified the mode explicitly.
|
void |
integerSetDirMode(int mode)
specify the user, group and
other modes in the standard Unix fashion;
optional, default=0755
|
void |
integerSetFileMode(int mode)
specify the user, group and
other modes in the standard Unix fashion;
optional, default=0644
|
boolean |
isFilesystemOnly()
Indicate whether this ResourceCollection is composed entirely of
Resources accessible via local filesystem conventions.
|
java.util.Iterator |
iterator()
Fulfill the ResourceCollection contract.
|
protected abstract ArchiveScanner |
newArchiveScanner()
Creates a scanner for this type of archive.
|
void |
setDir(java.io.File dir)
Set the directory for the fileset.
|
void |
setDirMode(java.lang.String octalString)
A 3 digit octal string, specify the user, group and
other modes in the standard Unix fashion;
optional, default=0755
|
void |
setFileMode(java.lang.String octalString)
A 3 digit octal string, specify the user, group and
other modes in the standard Unix fashion;
optional, default=0644
|
void |
setFullpath(java.lang.String fullpath)
Set the full pathname of the single entry in this fileset.
|
void |
setPrefix(java.lang.String prefix)
Prepend this prefix to the path for each archive entry.
|
void |
setSrc(java.io.File srcFile)
Set the source Archive file for the archivefileset.
|
void |
setSrcResource(Resource src)
Set the source Archive file for the archivefileset.
|
int |
size()
Fulfill the ResourceCollection contract.
|
java.lang.String |
toString()
For file-based archivefilesets, return the same as for normal filesets;
else just return the path of the zip.
|
add, addAnd, addContains, addContainsRegexp, addCustom, addDate, addDepend, addDepth, addDifferent, addFilename, addMajority, addModified, addNone, addNot, addOr, addPresent, addSelector, addSize, addType, appendExcludes, appendIncludes, appendSelector, createExclude, createExcludesFile, createInclude, createIncludesFile, createPatternSet, getDefaultexcludes, getDir, getDir, getDirectoryScanner, getRef, getSelectors, hasPatterns, hasSelectors, isCaseSensitive, isFollowSymlinks, mergeExcludes, mergeIncludes, mergePatterns, selectorCount, selectorElements, setCaseSensitive, setDefaultexcludes, setErrorOnMissingDir, setExcludes, setExcludesfile, setFile, setFollowSymlinks, setIncludes, setIncludesfile, setRefid, setupDirectoryScanner, setupDirectoryScanner
checkAttributesAllowed, checkChildrenAllowed, circularReference, dieOnCircularReference, dieOnCircularReference, dieOnCircularReference, getCheckedRef, getCheckedRef, getCheckedRef, getCheckedRef, getDataTypeName, getRefid, invokeCircularReferenceCheck, isChecked, isReference, noChildrenAllowed, setChecked, tooManyAttributes
getDescription, getLocation, getProject, log, log, setDescription, setLocation, setProject
public static final int DEFAULT_DIR_MODE
public static final int DEFAULT_FILE_MODE
public ArchiveFileSet()
protected ArchiveFileSet(FileSet fileset)
fileset
- the fileset to useprotected ArchiveFileSet(ArchiveFileSet fileset)
fileset
- the archivefileset to usepublic void setDir(java.io.File dir) throws BuildException
setDir
in class AbstractFileSet
dir
- the directory for the filesetBuildException
- on errorpublic void addConfigured(ResourceCollection a)
a
- the archive as a single element Resource collection.public void setSrc(java.io.File srcFile)
srcFile
- The archive from which to extract entries.public void setSrcResource(Resource src)
src
- The archive from which to extract entries.public java.io.File getSrc(Project p)
p
- the project to usepublic java.io.File getSrc()
public void setPrefix(java.lang.String prefix)
prefix
- The prefix to prepend to entries in the archive file.public java.lang.String getPrefix(Project p)
p
- the project to usepublic void setFullpath(java.lang.String fullpath)
fullpath
- the full pathname of the single entry in this fileset.public java.lang.String getFullpath(Project p)
p
- the project to useprotected abstract ArchiveScanner newArchiveScanner()
public DirectoryScanner getDirectoryScanner(Project p)
getDirectoryScanner
in class AbstractFileSet
p
- the project to usepublic java.util.Iterator iterator()
iterator
in interface ResourceCollection
iterator
in class FileSet
public int size()
size
in interface ResourceCollection
size
in class FileSet
public boolean isFilesystemOnly()
isFilesystemOnly
in interface ResourceCollection
isFilesystemOnly
in class FileSet
public void setFileMode(java.lang.String octalString)
octalString
- a String
valuepublic void integerSetFileMode(int mode)
We use the strange name so this method doesn't appear in IntrospectionHelpers list of attribute setters.
mode
- a int
valuepublic int getFileMode(Project p)
p
- the project to usepublic boolean hasFileModeBeenSet()
public void setDirMode(java.lang.String octalString)
octalString
- a String
valuepublic void integerSetDirMode(int mode)
We use the strange name so this method doesn't appear in IntrospectionHelpers list of attribute setters.
mode
- a int
valuepublic int getDirMode(Project p)
p
- the project to usepublic boolean hasDirModeBeenSet()
protected void configureFileSet(ArchiveFileSet zfs)
zfs
- the project to usepublic java.lang.Object clone()
public java.lang.String toString()
toString
in class AbstractFileSet
public java.lang.String getPrefix()
public java.lang.String getFullpath()
public int getFileMode()
public int getDirMode()