Coverts a path to a fileset. This is usefull if you have a path but need to use a fileset as input in a ant task.


Attribute Description Required
dir The root of the directory tree of this FileSet Yes
pathrefid The reference to the path to convert from Yes
ignorenonrelative This boolean controls what will happen if any of the files in the path are not in the directory for the fileset. If this is "true" the files are ignored, if this is "false" a build exception is thrown. (Note: if files are not present no check is made). No, default is "false"
name This is the identifier of the fileset to create. This fileset will contain the files that are relative to the directory root. Any files that are not present will not be placed in the set. Yes


    <outofdate outputsourcespath="modified.sources.path">
        <fileset dir="a/b/c" includes="**/*.java"/>
      <mapper dir="a/b/c" type="glob" from="*.java" to="output/*.xml"/>
        <pathtofileset name="modified.sources.fileset"
        <copy todir="output">
          <fileset refid="modified.sources.fileset"/>
          <mapper type="glob" from="*.java" to="*.xml"/>

Copyright © 2003 Ant-Contrib Project. All rights Reserved.