| <html> |
| |
| <head> |
| <meta http-equiv="Content-Language" content="en-us"> |
| <title>FileSet Type</title> |
| </head> |
| |
| <body> |
| |
| <h2><a name="fileset">FileSet</a></h2> |
| <p>FileSets are groups of files. These files can be found in a |
| directory tree starting in a base directory and are matched by |
| patterns taken from a number of <a |
| href="patternset.html">PatternSets</a>. FileSets can appear inside tasks |
| that support this feature or at the same level as <code>target</code> |
| - i.e., as children of <code>project</code>.</p> |
| <p>PatternSets can be specified as nested |
| <code><patternset></code> elements. In addition, FileSet holds |
| an implicit PatternSet and supports the nested |
| <code><include></code>, <code><includesfile></code>, |
| <code><exclude></code> and <code><excludesfile></code> |
| elements of PatternSet directly, as well as PatternSet's |
| attributes.</p> |
| <table border="1" cellpadding="2" cellspacing="0"> |
| <tr> |
| <td valign="top"><b>Attribute</b></td> |
| <td valign="top"><b>Description</b></td> |
| <td align="center" valign="top"><b>Required</b></td> |
| </tr> |
| <tr> |
| <td valign="top">dir</td> |
| <td valign="top">the root of the directory tree of this FileSet.</td> |
| <td valign="top" align="center">Yes</td> |
| </tr> |
| <tr> |
| <td valign="top">defaultexcludes</td> |
| <td valign="top">indicates whether <a href="../dirtasks.html#defaultexcludes">default excludes</a> should be used or not |
| (<code>yes | no</code>); default excludes are used when omitted.</td> |
| <td valign="top" align="center">No</td> |
| </tr> |
| <tr> |
| <td valign="top">includes</td> |
| <td valign="top">comma- or space-separated list of patterns of files that must be |
| included; all files are included when omitted.</td> |
| <td valign="top" align="center">No</td> |
| </tr> |
| <tr> |
| <td valign="top">includesfile</td> |
| <td valign="top">the name of a file; each line of this file is |
| taken to be an include pattern.</td> |
| <td valign="top" align="center">No</td> |
| </tr> |
| <tr> |
| <td valign="top">excludes</td> |
| <td valign="top">comma- or space-separated list of patterns of files that must be |
| excluded; no files (except default excludes) are excluded when omitted.</td> |
| <td valign="top" align="center">No</td> |
| </tr> |
| <tr> |
| <td valign="top">excludesfile</td> |
| <td valign="top">the name of a file; each line of this file is |
| taken to be an exclude pattern.</td> |
| <td valign="top" align="center">No</td> |
| </tr> |
| <tr> |
| <td valign="top">casesensitive</td> |
| <td valign="top">Must the file system be treated in a case sensitive way? |
| Defaults to true.</td> |
| <td valign="top" align="center">No</td> |
| </tr> |
| <tr> |
| <td valign="top">followsymlinks</td> |
| <td valign="top">Shall symbolic links be followed? Defaults to |
| true. See <a href="symlink">below</a>.</td> |
| <td valign="top" align="center">No</td> |
| </tr> |
| </table> |
| |
| <p><a name="symlink"><b>Note</b></a>: All files/directories for which |
| the canonical path is different from its path are considered symbolic |
| links. On Unix systems this usually means the file really is a |
| symbolic links but it may lead to false results on other |
| platforms.</p> |
| |
| <h4>Examples</h4> |
| <blockquote><pre> |
| <fileset dir="${server.src}" casesensitive="yes" > |
| <include name="**/*.java"/> |
| <exclude name="**/*Test*"/> |
| </fileset> |
| </pre></blockquote> |
| <p>Groups all files in directory <code>${server.src}</code> that are Java |
| source files and don't have the text <code>Test</code> in their |
| name.</p> |
| <blockquote><pre> |
| <fileset dir="${server.src}" casesensitive="yes" > |
| <patternset id="non.test.sources" > |
| <include name="**/*.java"/> |
| <exclude name="**/*Test*"/> |
| </patternset> |
| </fileset> |
| </pre></blockquote> |
| <p>Groups the same files as the above example, but also establishes |
| a PatternSet that can be referenced in other |
| <code><fileset></code> elements, rooted at a different directory.</p> |
| <blockquote><pre> |
| <fileset dir="${client.src}" > |
| <patternset refid="non.test.sources"/> |
| </fileset> |
| </pre></blockquote> |
| <p>Groups all files in directory <code>${client.src}</code>, using the |
| same patterns as the above example.</p> |
| |
| <hr> |
| <p align="center">Copyright © 2000-2002 Apache Software Foundation. |
| All rights Reserved.</p> |
| |
| </body> |
| </html> |
| |