public abstract class AbstractFileTree extends AbstractFileCollection implements FileTree
FileCollection.AntType| Constructor and Description |
|---|
AbstractFileTree() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addAsResourceCollection(Object builder,
String nodeName) |
FileTree |
getAsFileTree()
Converts this collection to a
FileTree. |
Map<String,File> |
getAsMap() |
Set<File> |
getFiles()
Returns the contents of this collection as a Set.
|
boolean |
isEmpty()
Returns true if this collection is empty.
|
FileTree |
matching(Closure filterConfigClosure)
Restricts the contents of this tree to those files matching the given filter.
|
FileTree |
matching(PatternFilterable patterns)
Restricts the contents of this tree to those files matching the given filter.
|
FileTree |
plus(FileTree fileTree)
Returns a
FileTree which contains the union of this tree and the given tree. |
FileTree |
visit(Closure closure)
Visits the files and directories in this file tree.
|
protected boolean |
visitAll()
Visits all the files of this tree.
|
add, addAsFileSet, addAsMatchingTask, addToAntBuilder, addToAntBuilder, asType, contains, filter, filter, getAsFileTrees, getAsPath, getBuildDependencies, getCapDisplayName, getDisplayName, getSingleFile, iterator, minus, plus, stopExecutionIfEmpty, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitadd, addToAntBuilder, addToAntBuilder, asType, contains, filter, filter, getAsPath, getSingleFile, minus, plus, stopExecutionIfEmptygetBuildDependenciespublic Set<File> getFiles()
FileCollectiongetFiles in interface FileCollectiongetFiles in interface MinimalFileSetpublic boolean isEmpty()
FileCollectiongetFiles().isEmpty().isEmpty in interface FileCollectionisEmpty in class AbstractFileCollectionpublic FileTree matching(Closure filterConfigClosure)
FileTreeRestricts the contents of this tree to those files matching the given filter. The filtered tree is live, so that any changes to this tree are reflected in the filtered tree.
The given closure is used to configure the filter. A PatternFilterable is
passed to the closure as it's delegate. Only files which match the specified include patterns will be included in
the filtered tree. Any files which match the specified exclude patterns will be excluded from the filtered
tree.
public FileTree matching(PatternFilterable patterns)
FileTreeRestricts the contents of this tree to those files matching the given filter. The filtered tree is live, so that any changes to this tree are reflected in the filtered tree.
The given pattern set is used to configure the filter. Only files which match the specified include patterns will be included in the filtered tree. Any files which match the specified exclude patterns will be excluded from the filtered tree.
protected void addAsResourceCollection(Object builder, String nodeName)
addAsResourceCollection in class AbstractFileCollectionprotected boolean visitAll()
public FileTree getAsFileTree()
FileCollectionFileTree. Generally, for each file in this collection, the resulting file
tree will contain the source file at the root of the tree. For each directory in this collection, the resulting
file tree will contain all the files under the source directory.getAsFileTree in interface FileCollectiongetAsFileTree in interface FileTreegetAsFileTree in class AbstractFileCollectionFileTree. Never returns null.public FileTree plus(FileTree fileTree)
FileTreeFileTree which contains the union of this tree and the given tree. The returned tree is live,
so that changes to either this tree or the other source tree are reflected in the returned tree.public FileTree visit(Closure closure)
FileTreeFileVisitDetailsCopyright © 2013. All rights reserved