You can not select more than 25 topics
Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
- <html>
-
- <head>
- <meta http-equiv="Content-Language" content="en-us">
- <title>Ant User Manual</title>
- </head>
-
- <body>
-
- <h2><a name="antjar">AntJar</a></h2>
- <h3>Description</h3>
- <p>An extension of the <a href="jar.html">Jar</a> task with special
- treatment for the library descriptor file that should end up in the
- <code>META-INF</code> directory of the Ant Archive.</p>
- <p>This task validates the provided library descriptor making certain
- it specifies the following SYSTEM ID:
- <b>"http://jakarta.apache.org/ant/AntlibV1_0.dtd"</b>.
- This DTD is defined as follows:</p>
- <pre>
- <?xml version='1.0' encoding="UTF8" ?>
-
- <!--
- This file defines the XML format for ANT library descriptors.
- Descriptors must especify a DOCTYPE of
- "http://jakarta.apache.org/ant/Antlib-V1_0.dtd"
- as the SystemId for the document.
- -->
-
- <!-- Root element for the Antlib descriptor. -->
- <!ELEMENT antlib (task | type)* >
- <!ATTLIST antlib
- version CDATA #IMPLIED
- >
-
- <!-- Declaration of tasks contained in the library. -->
- <!ELEMENT task EMPTY>
- <!ATTLIST task
- name CDATA #REQUIRED
- class CDATA #REQUIRED
- >
-
- <!-- Declaration of datatypes contained in the library -->
- <!ELEMENT type EMPTY>
- <!ATTLIST type
- name CDATA #REQUIRED
- class CDATA #REQUIRED
- >
-
- </pre>
- <h3>Parameters</h3>
- <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">antxml</td>
- <td valign="top">The library descriptor to use (META-INF/antlib.xml).</td>
- <td valign="top" align="center">Yes</td>
- </tr>
- <tr>
- <td valign="top"><b>Others...</b></td>
- <td valign="top">All attributes inherited form the
- <a href="jar.html">Jar task</a>.</td>
- <td valign="top" align="center"> </td>
- </tr>
- </table>
- <h3>Nested elements</h3>
- See the nested elements of the <a href="jar.html">Jar task</a>.
- <h3>Examples</h3>
- <pre> <antjar file="${dist}/lib/app.jar"
- antxml="${src}/applib.xml" basedir="${build}/classes"/></pre>
- <p>jars all files in the <code>${build}/classes</code> directory into a file
- called <code>app.jar</code> in the <code>${dist}/lib</code> directory and
- sets the content of <code>${src}/applib.xml</code> as the library descriptor
- in <code>META-INF/antlib.xml</code>.</p>
- <p>Here is a sample <code>META-INF/antlib.xml</code>:</p>
- <pre>
- <?xml version="1.0" encoding="UTF8" ?>
- <!DOCTYPE antlib SYSTEM "http://jakarta.apache.org/ant/Antlib-V1_0.dtd" >
-
- <antlib version="1.0" >
- <task name="case" class="org.apache.ant.contrib.Case" />
- </antlib>
-
- </pre>
- <hr>
- <p align="center">Copyright © 2000,2001 Apache Software Foundation. All rights
- Reserved.</p>
-
- </body>
- </html>
|