Methods Summary |
---|
public void | addFileset(org.apache.tools.ant.types.FileSet fileset)
filesets.addElement(fileset);
|
public ParamItem | createItem()
ParamItem item = new ParamItem();
items.addElement(item);
return item;
|
protected java.lang.String[] | getDirs(java.io.File basedir, org.apache.tools.ant.DirectoryScanner ds)Return the list of Directories from this DirectoryScanner that
should be included on the command line.
return ds.getIncludedDirectories();
|
protected java.lang.String[] | getFiles(java.io.File basedir, org.apache.tools.ant.DirectoryScanner ds)Return the list of files from this DirectoryScanner that should
be included on the command line.
return ds.getIncludedFiles();
|
public java.lang.String | getName()
return name;
|
public java.util.Enumeration | getValues(org.apache.tools.ant.Project project)
/* As an arbitrary rule, this will return filesets first,
and then <item>s. The ordering of the buildfile is
not guaranteed. */
Vector values = new Vector();
Enumeration enum = filesets.elements();
while (enum.hasMoreElements()) {
FileSet fileSet = (FileSet) enum.nextElement();
File base = fileSet.getDir(project);
DirectoryScanner scanner = fileSet.getDirectoryScanner(project);
if (TYPE_DIR != type) {
String[] files = getFiles(base, scanner);
for (int j = 0; j < files.length; j++) {
File f = new File(base, files[j]);
values.addElement(f.getAbsolutePath());
}
}
if (TYPE_FILE != type) {
String[] dirs = getDirs(base, scanner);
for (int j = 0; j < dirs.length; j++) {
File f = new File(base, dirs[j]);
values.addElement(f.getAbsolutePath());
}
}
}
enum = items.elements();
while (enum.hasMoreElements()) {
ParamItem item = (ParamItem) enum.nextElement();
values.addElement(item.getValue());
}
return values.elements();
|
public void | setName(java.lang.String name)
this.name = name;
|
public void | setType(org.apache.axis.tools.ant.foreach.ParamSet$FileDirBoth type)Shall the command work only on files, directories or both?
this.type = type.getValue().intern();
|