|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.apache.tools.ant.ProjectComponent
org.apache.tools.ant.types.DataType
org.apache.tools.ant.types.FileList
public class FileList
FileList represents an explicitly named list of files. FileLists are useful when you want to capture a list of files regardless of whether they currently exist. By contrast, FileSet operates as a filter, only returning the name of a matched file if it currently exists in the file system.
| Nested Class Summary | |
|---|---|
static class |
FileList.FileName
Inner class corresponding to the <file> nested element. |
| Field Summary |
|---|
| Fields inherited from class org.apache.tools.ant.types.DataType |
|---|
checked, ref |
| Fields inherited from class org.apache.tools.ant.ProjectComponent |
|---|
description, location, project |
| Constructor Summary | |
|---|---|
|
FileList()
The default constructor. |
protected |
FileList(FileList filelist)
A copy constructor. |
| Method Summary | |
|---|---|
void |
addConfiguredFile(FileList.FileName name)
Add a nested <file> nested element. |
java.io.File |
getDir(Project p)
|
java.lang.String[] |
getFiles(Project p)
Returns the list of files represented by this FileList. |
protected FileList |
getRef(Project p)
Performs the check for circular references and returns the referenced FileList. |
boolean |
isFilesystemOnly()
Always returns true. |
java.util.Iterator |
iterator()
Fulfill the ResourceCollection contract. |
void |
setDir(java.io.File dir)
Set the dir attribute. |
void |
setFiles(java.lang.String filenames)
Set the filenames attribute. |
void |
setRefid(Reference r)
Makes this instance in effect a reference to another FileList instance. |
int |
size()
Fulfill the ResourceCollection contract. |
| Methods inherited from class org.apache.tools.ant.types.DataType |
|---|
checkAttributesAllowed, checkChildrenAllowed, circularReference, clone, dieOnCircularReference, dieOnCircularReference, dieOnCircularReference, getCheckedRef, getCheckedRef, getCheckedRef, getCheckedRef, getDataTypeName, getRefid, invokeCircularReferenceCheck, isChecked, isReference, noChildrenAllowed, setChecked, tooManyAttributes, toString |
| Methods inherited from class org.apache.tools.ant.ProjectComponent |
|---|
getDescription, getLocation, getProject, log, log, setDescription, setLocation, setProject |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public FileList()
protected FileList(FileList filelist)
filelist - a FileList value| Method Detail |
|---|
public void setRefid(Reference r)
throws BuildException
You must not set another attribute or nest elements inside this element if you make it a reference.
setRefid in class DataTyper - the reference to another filelist.
BuildException - if an error occurs.
public void setDir(java.io.File dir)
throws BuildException
dir - the directory this filelist is relative to.
BuildException - if an error occurspublic java.io.File getDir(Project p)
p - the current project
public void setFiles(java.lang.String filenames)
filenames - a string contains filenames, separated by , or
by whitespace.public java.lang.String[] getFiles(Project p)
p - the current project
protected FileList getRef(Project p)
p - the current project
public void addConfiguredFile(FileList.FileName name)
name - a configured file element with a name.public java.util.Iterator iterator()
iterator in interface ResourceCollectionpublic int size()
size in interface ResourceCollectionpublic boolean isFilesystemOnly()
isFilesystemOnly in interface ResourceCollection
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||