public class FileTreeAdapter extends AbstractFileTree implements FileCollectionContainer
MinimalFileTree into a full FileTree implementation.FileCollection.AntType| Constructor and Description |
|---|
FileTreeAdapter(MinimalFileTree tree) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
contains(File file)
Determines whether this collection contains the given file.
|
protected Collection<DirectoryFileTree> |
getAsFileTrees()
Returns this collection as a set of
DirectoryFileTree instances. |
TaskDependency |
getBuildDependencies()
Returns a dependency which contains the tasks which build this artifact.
|
String |
getDisplayName()
Returns the display name of this file collection.
|
MinimalFileTree |
getTree() |
FileTree |
matching(PatternFilterable patterns)
Restricts the contents of this tree to those files matching the given filter.
|
void |
resolve(FileCollectionResolveContext context)
Adds the contents of this container to the given context.
|
FileTree |
visit(FileVisitor visitor)
Visits the files and directories in this file tree.
|
addAsResourceCollection, getAsFileTree, getAsMap, getFiles, isEmpty, matching, plus, visit, visitAlladd, addAsFileSet, addAsMatchingTask, addToAntBuilder, addToAntBuilder, asType, filter, filter, getAsPath, getCapDisplayName, getSingleFile, iterator, minus, plus, stopExecutionIfEmpty, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitadd, addToAntBuilder, addToAntBuilder, asType, filter, filter, getAsPath, getSingleFile, minus, plus, stopExecutionIfEmptypublic FileTreeAdapter(MinimalFileTree tree)
public MinimalFileTree getTree()
public String getDisplayName()
AbstractFileCollectiongetDisplayName in interface FileCollectionContainergetDisplayName in interface MinimalFileCollectiongetDisplayName in class AbstractFileCollectionpublic void resolve(FileCollectionResolveContext context)
FileCollectionContainerresolve in interface FileCollectionContainerprotected Collection<DirectoryFileTree> getAsFileTrees()
AbstractFileCollectionDirectoryFileTree instances.getAsFileTrees in class AbstractFileCollectionpublic TaskDependency getBuildDependencies()
BuildableBuildable implementations
must ensure that the returned dependency object is live, so that it tracks changes to the dependencies of this
buildable.getBuildDependencies in interface BuildablegetBuildDependencies in class AbstractFileCollectionpublic boolean contains(File file)
FileCollectiongetFiles().contains(file).contains in interface FileCollectioncontains in class AbstractFileCollectionfile - The file to check for.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.
matching in interface FileTreematching in class AbstractFileTreepatterns - the pattern set to use to configure the filter.public FileTree visit(FileVisitor visitor)
FileTreeCopyright © 2013. All rights reserved