ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Arun Gupta <>
Subject Deriving from MatchingTask
Date Thu, 03 Mar 2005 21:01:10 GMT
I'm writing a custom task that require to support
"includes" attribute and nested fileset elements to
specify the location of source files. The source file
list should be a union of files specified in the
"includes" attribute and those specified in the nested
fileset element (is that a correct expectation?) I
understand how to deal with the nested fileset
elements but not able to figure out how to deal with
the source files specified in the "includes"
attribute. Here is how my source code looks like:

if (getSourcePath() != null) {
DirectoryScanner ds = getDirectoryScanner(new
// what do I specify as arguments here ?
String[] includedFiles = ds.getIncludedFiles();
File baseDir = ds.getBasedir();
for (int i=0; i<includedFiles.length; ++i) {
  sourceFiles.add(new File(baseDir,

My question really is what do I specify as an argument
to getDirectoryScanner ?

Also, searching in the list archives, I've seen it's
not recommended [1] to use MatchingTask as the parent
class. What is the motivation behind that
recommendation ? Is it going to be deprecated in a
subsequent release ?



Celebrate Yahoo!'s 10th Birthday! 
Yahoo! Netrospective: 100 Moments of the Web

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message