>> Just for information:
>> - The 'dir' attribute must be exactly one value, because it is the
>> root for
>
>Any reason we can't add a runtime test to check if the
>supplied value is not a directory and if so that an
>appropriate exception?
As shown in the tutorial [1], using filesets is done like
FileSet fs = (FileSet)itFSets.next();
DirectoryScanner ds = fs.getDirectoryScanner(getProject());
String[] includedFiles = ds.getIncludedFiles();
This results in AbstractFileSet.getDirectoryScanner(Project) [2]:
...
if (dir == null) {
throw new BuildException("No directory specified for " +
getDataTypeName() + ".");
}
if (!dir.exists()) {
throw new BuildException(dir.getAbsolutePath() + " not found.");
}
if (!dir.isDirectory()) {
throw new BuildException(dir.getAbsolutePath() + " is not a
directory.");
}
What additional exceptions do you want?
Jan
[1]
http://svn.apache.org/repos/asf/ant/core/trunk/docs/manual/tutorial-task
s-filesets-properties.html
http://ant.apache.org/manual/tutorial-tasks-filesets-properties.html
[2]
http://svn.apache.org/repos/asf/ant/core/trunk/src/main/org/apache/tools
/ant/types/AbstractFileSet.java
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]