1 | <!--
|
---|
2 | Licensed to the Apache Software Foundation (ASF) under one or more
|
---|
3 | contributor license agreements. See the NOTICE file distributed with
|
---|
4 | this work for additional information regarding copyright ownership.
|
---|
5 | The ASF licenses this file to You under the Apache License, Version 2.0
|
---|
6 | (the "License"); you may not use this file except in compliance with
|
---|
7 | the License. You may obtain a copy of the License at
|
---|
8 |
|
---|
9 | http://www.apache.org/licenses/LICENSE-2.0
|
---|
10 |
|
---|
11 | Unless required by applicable law or agreed to in writing, software
|
---|
12 | distributed under the License is distributed on an "AS IS" BASIS,
|
---|
13 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
---|
14 | See the License for the specific language governing permissions and
|
---|
15 | limitations under the License.
|
---|
16 | -->
|
---|
17 | <html>
|
---|
18 |
|
---|
19 | <head>
|
---|
20 | <meta http-equiv="Content-Language" content="en-us">
|
---|
21 | <link rel="stylesheet" type="text/css" href="../stylesheets/style.css">
|
---|
22 | <title>FileList Type</title>
|
---|
23 | </head>
|
---|
24 |
|
---|
25 | <body>
|
---|
26 |
|
---|
27 | <h2><a name="filelist">FileList</a></h2>
|
---|
28 |
|
---|
29 | <p>FileLists are explicitly named lists of files. Whereas FileSets
|
---|
30 | act as filters, returning only those files that exist in the file
|
---|
31 | system and match specified patterns, FileLists are useful for
|
---|
32 | specifying files that may or may not exist. Multiple files are
|
---|
33 | specified as a list of files, relative to the specified directory,
|
---|
34 | with no support for wildcard expansion (filenames with wildcards will be
|
---|
35 | included in the list unchanged).
|
---|
36 | FileLists can appear inside tasks that support this feature or as stand-alone
|
---|
37 | types.
|
---|
38 | </p>
|
---|
39 | <table border="1" cellpadding="2" cellspacing="0">
|
---|
40 | <tr>
|
---|
41 | <td valign="top"><b>Attribute</b></td>
|
---|
42 | <td valign="top"><b>Description</b></td>
|
---|
43 | <td align="center" valign="top"><b>Required</b></td>
|
---|
44 | </tr>
|
---|
45 | <tr>
|
---|
46 | <td valign="top">dir</td>
|
---|
47 | <td valign="top">The base directory of this FileList.</td>
|
---|
48 | <td valign="top" align="center">Yes</td>
|
---|
49 | </tr>
|
---|
50 | <tr>
|
---|
51 | <td valign="top">files</td>
|
---|
52 | <td valign="top">The list of file names. This is a list of
|
---|
53 | file name separated by whitespace, or by commas.</td>
|
---|
54 | <td valign="top" align="center">
|
---|
55 | Yes, unless there is a nested file element</td>
|
---|
56 | </tr>
|
---|
57 | </table>
|
---|
58 | <h4>Nested Element: file</h4>
|
---|
59 | <p>
|
---|
60 | This represents a file name. The nested element allows filenames containing
|
---|
61 | white space and commas.
|
---|
62 | </p>
|
---|
63 | <p><em>Since Ant 1.6.2</em></p>
|
---|
64 | <table border="1" cellpadding="2" cellspacing="0">
|
---|
65 | <tr>
|
---|
66 | <td valign="top"><b>Attribute</b></td>
|
---|
67 | <td valign="top"><b>Description</b></td>
|
---|
68 | <td align="center" valign="top"><b>Required</b></td>
|
---|
69 | </tr>
|
---|
70 | <tr>
|
---|
71 | <td valign="top">name</td>
|
---|
72 | <td valign="top">The name of the file.</td>
|
---|
73 | <td valign="top" align="center">Yes</td>
|
---|
74 | </tr>
|
---|
75 | </table>
|
---|
76 | <h3>Examples</h3>
|
---|
77 | <blockquote><pre>
|
---|
78 | <filelist
|
---|
79 | id="docfiles"
|
---|
80 | dir="${doc.src}"
|
---|
81 | files="foo.xml,bar.xml"/>
|
---|
82 | </pre></blockquote>
|
---|
83 |
|
---|
84 | <p>The files <code>${doc.src}/foo.xml</code> and
|
---|
85 | <code>${doc.src}/bar.xml</code>. Note that these files may not (yet)
|
---|
86 | actually exist.
|
---|
87 | </p>
|
---|
88 |
|
---|
89 | <blockquote><pre>
|
---|
90 | <filelist
|
---|
91 | id="docfiles"
|
---|
92 | dir="${doc.src}"
|
---|
93 | files="foo.xml
|
---|
94 | bar.xml"/>
|
---|
95 | </pre></blockquote>
|
---|
96 |
|
---|
97 | <p>Same files as the example above.</p>
|
---|
98 |
|
---|
99 | <blockquote><pre>
|
---|
100 | <filelist refid="docfiles"/>
|
---|
101 | </pre></blockquote>
|
---|
102 |
|
---|
103 | <p>Same files as the example above.</p>
|
---|
104 |
|
---|
105 | <blockquote><pre>
|
---|
106 | <filelist
|
---|
107 | id="docfiles"
|
---|
108 | dir="${doc.src}">
|
---|
109 | <file name="foo.xml"/>
|
---|
110 | <file name="bar.xml"/>
|
---|
111 | </filelist>
|
---|
112 | </pre></blockquote>
|
---|
113 |
|
---|
114 | <p>Same files as the example above.</p>
|
---|
115 |
|
---|
116 |
|
---|
117 |
|
---|
118 | </body>
|
---|
119 | </html>
|
---|
120 |
|
---|