Package org.apache.tools.ant.types
Class TarFileSet
- All Implemented Interfaces:
- Cloneable,- Iterable<Resource>,- ResourceCollection,- SelectorContainer
- Direct Known Subclasses:
- Tar.TarFileSet
A TarFileSet is a FileSet with extra attributes useful in the context of
 Tar/Jar tasks.
 A TarFileSet extends FileSets with the ability to extract a subset of the
 entries of a Tar file for inclusion in another Tar file.  It also includes
 a prefix attribute which is prepended to each entry in the output Tar file.
- 
Field SummaryFields inherited from class org.apache.tools.ant.types.ArchiveFileSetDEFAULT_DIR_MODE, DEFAULT_FILE_MODEFields inherited from class org.apache.tools.ant.ProjectComponentdescription, location, project
- 
Constructor SummaryConstructorsModifierConstructorDescriptionConstructor for TarFileSetprotectedTarFileSet(FileSet fileset) Constructor using a fileset argument.protectedTarFileSet(TarFileSet fileset) Constructor using a tarfileset argument.
- 
Method SummaryModifier and TypeMethodDescriptionclone()Return a TarFileSet that has the same properties as this one.protected voidConfigure a fileset based on this fileset.intgetGid()getGroup()protected AbstractFileSetgetRef()A TarFileset accepts another TarFileSet or a FileSet as reference FileSets are often used by the war task for the lib attributeprotected AbstractFileSetA TarFileset accepts another TarFileSet or a FileSet as reference FileSets are often used by the war task for the lib attributeintgetUid()booleanbooleanbooleanbooleanprotected ArchiveScannerCreate a new scanner.voidsetGid(int gid) The GID for the tar entry; optional, default="0" This is not the same as the group name.voidThe groupname for the tar entry; optional, default="" This is not the same as the GID.voidMakes this instance in effect a reference to another instance.voidsetUid(int uid) The uid for the tar entry This is not the same as the User name.voidsetUserName(String userName) The username for the tar entry This is not the same as the UID.Methods inherited from class org.apache.tools.ant.types.ArchiveFileSetaddConfigured, dieOnCircularReference, getDirectoryScanner, getDirMode, getDirMode, getEncoding, getFileMode, getFileMode, getFullpath, getFullpath, getPrefix, getPrefix, getSrc, getSrc, hasDirModeBeenSet, hasFileModeBeenSet, integerSetDirMode, integerSetFileMode, isFilesystemOnly, iterator, setDir, setDirMode, setEncoding, setErrorOnMissingArchive, setFileMode, setFullpath, setPrefix, setSrc, setSrcResource, size, toStringMethods inherited from class org.apache.tools.ant.types.AbstractFileSetadd, addAnd, addContains, addContainsRegexp, addCustom, addDate, addDepend, addDepth, addDifferent, addExecutable, addFilename, addMajority, addModified, addNone, addNot, addOr, addOwnedBy, addPosixGroup, addPosixPermissions, addPresent, addReadable, addSelector, addSize, addSymlink, addType, addWritable, appendExcludes, appendIncludes, appendSelector, createExclude, createExcludesFile, createInclude, createIncludesFile, createPatternSet, getDefaultexcludes, getDir, getDir, getDirectoryScanner, getErrorOnMissingDir, getMaxLevelsOfSymlinks, getSelectors, hasPatterns, hasSelectors, isCaseSensitive, isFollowSymlinks, mergeExcludes, mergeIncludes, mergePatterns, selectorCount, selectorElements, setCaseSensitive, setDefaultexcludes, setErrorOnMissingDir, setExcludes, setExcludesfile, setFile, setFollowSymlinks, setIncludes, setIncludesfile, setMaxLevelsOfSymlinks, setupDirectoryScanner, setupDirectoryScannerMethods inherited from class org.apache.tools.ant.types.DataTypecheckAttributesAllowed, checkChildrenAllowed, circularReference, dieOnCircularReference, dieOnCircularReference, getCheckedRef, getCheckedRef, getCheckedRef, getCheckedRef, getCheckedRef, getDataTypeName, getRefid, invokeCircularReferenceCheck, isChecked, isReference, noChildrenAllowed, pushAndInvokeCircularReferenceCheck, setChecked, tooManyAttributesMethods inherited from class org.apache.tools.ant.ProjectComponentgetDescription, getLocation, getProject, log, log, setDescription, setLocation, setProjectMethods inherited from class java.lang.Objectequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface java.lang.IterableforEach, spliteratorMethods inherited from interface org.apache.tools.ant.types.ResourceCollectionisEmpty, stream
- 
Constructor Details- 
TarFileSetpublic TarFileSet()Constructor for TarFileSet
- 
TarFileSetConstructor using a fileset argument.- Parameters:
- fileset- the fileset to use
 
- 
TarFileSetConstructor using a tarfileset argument.- Parameters:
- fileset- the tarfileset to use
 
 
- 
- 
Method Details- 
setUserNameThe username for the tar entry This is not the same as the UID.- Parameters:
- userName- the user name for the tar entry.
 
- 
getUserName- Returns:
- the user name for the tar entry
 
- 
hasUserNameBeenSetpublic boolean hasUserNameBeenSet()- Returns:
- whether the user name has been explicitly set.
 
- 
setUidpublic void setUid(int uid) The uid for the tar entry This is not the same as the User name.- Parameters:
- uid- the id of the user for the tar entry.
 
- 
getUidpublic int getUid()- Returns:
- the uid for the tar entry
 
- 
hasUserIdBeenSetpublic boolean hasUserIdBeenSet()- Returns:
- whether the user id has been explicitly set.
 
- 
setGroupThe groupname for the tar entry; optional, default="" This is not the same as the GID.- Parameters:
- groupName- the group name string.
 
- 
getGroup- Returns:
- the group name string.
 
- 
hasGroupBeenSetpublic boolean hasGroupBeenSet()- Returns:
- whether the group name has been explicitly set.
 
- 
setGidpublic void setGid(int gid) The GID for the tar entry; optional, default="0" This is not the same as the group name.- Parameters:
- gid- the group id.
 
- 
getGidpublic int getGid()- Returns:
- the group identifier.
 
- 
hasGroupIdBeenSetpublic boolean hasGroupIdBeenSet()- Returns:
- whether the group id has been explicitly set.
 
- 
newArchiveScannerCreate a new scanner.- Specified by:
- newArchiveScannerin class- ArchiveFileSet
- Returns:
- the created scanner.
 
- 
setRefidMakes this instance in effect a reference to another instance.You must not set another attribute or nest elements inside this element if you make it a reference. - Overrides:
- setRefidin class- AbstractFileSet
- Parameters:
- r- the- Referenceto use.
- Throws:
- BuildException- on error
 
- 
getRefA TarFileset accepts another TarFileSet or a FileSet as reference FileSets are often used by the war task for the lib attribute
- 
getRefA TarFileset accepts another TarFileSet or a FileSet as reference FileSets are often used by the war task for the lib attribute- Overrides:
- getRefin class- ArchiveFileSet
- Returns:
- the abstract fileset instance
 
- 
configureFileSetConfigure a fileset based on this fileset. If the fileset is a TarFileSet copy in the tarfileset specific attributes.- Overrides:
- configureFileSetin class- ArchiveFileSet
- Parameters:
- zfs- the archive fileset to configure.
 
- 
cloneReturn a TarFileSet that has the same properties as this one.- Overrides:
- clonein class- ArchiveFileSet
- Returns:
- the cloned tarFileSet
 
 
-