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.

javadoc.html 30 KiB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791
  1. <html>
  2. <head>
  3. <meta http-equiv="Content-Language" content="en-us">
  4. <title>Javadoc Task</title>
  5. </head>
  6. <body>
  7. <h2><a name="javadoc">Javadoc/<i>Javadoc2</i></a></h2>
  8. <h3>Description</h3>
  9. <p>Generates code documentation using the javadoc tool.</p>
  10. <p>The source directory will be recursively scanned for Java source files to process
  11. but only those matching the inclusion rules, and not matching the exclusions rules
  12. will be passed to the javadoc tool. This
  13. allows wildcards to be used to choose between package names, reducing verbosity
  14. and management costs over time. This task, however, has no notion of
  15. &quot;changed&quot; files, unlike the <a href="javac.html">javac</a> task. This means
  16. all packages will be processed each time this task is run. In general, however,
  17. this task is used much less frequently.</p>
  18. <p>This task works seamlessly between different javadoc versions (1.1,
  19. 1.2 and 1.4), with the obvious restriction that the 1.2 attributes
  20. will be ignored if run in a 1.1 VM.</p>
  21. <p>NOTE: since javadoc calls System.exit(), javadoc cannot be run inside the
  22. same VM as ant without breaking functionality. For this reason, this task
  23. always forks the VM. This overhead is not significant since javadoc is normally a heavy
  24. application and will be called infrequently.</p>
  25. <p>NOTE: the packagelist attribute allows you to specify the list of packages to
  26. document outside of the Ant file. It's a much better practice to include everything
  27. inside the build.xml file. This option was added in order to make it easier to
  28. migrate from regular makefiles, where you would use this option of javadoc.
  29. The packages listed in packagelist are not checked, so the task performs even
  30. if some packages are missing or broken. Use this option if you wish to convert from
  31. an existing makefile. Once things are running you should then switch to the regular
  32. notation. </p>
  33. <p><i><b>DEPRECATION:</b> the javadoc2 task simply points to the javadoc task and it's
  34. there for back compatibility reasons. Since this task will be removed in future
  35. versions, you are strongly encouraged to use <a href="javadoc.html">javadoc</a>
  36. instead.</i></p>
  37. <p>In the table below, 1.1 means available if your current Java VM is
  38. a 1.1 VM, 1.2 for either 1.2 or 1.3 and 1.4+ for any VM of at least version 1.4. 1.2+
  39. means any VM of at least version 1.2.</p>
  40. <h3>Parameters</h3>
  41. <table border="1" cellpadding="2" cellspacing="0">
  42. <tr>
  43. <td valign="top"><b>Attribute</b></td>
  44. <td valign="top"><b>Description</b></td>
  45. <td align="center" valign="top"><b>Availability</b></td>
  46. <td align="center" valign="top"><b>Required</b></td>
  47. </tr>
  48. <tr>
  49. <td valign="top">sourcepath</td>
  50. <td valign="top">Specify where to find source files</td>
  51. <td align="center" valign="top">all</td>
  52. <td align="center" rowspan="3">At least one of the three or nested
  53. <code>&lt;sourcepath&gt;</code>, <code>&lt;fileset&gt;</code> or
  54. <code>&lt;packageset&gt;</code></td>
  55. </tr>
  56. <tr>
  57. <td valign="top">sourcepathref</td>
  58. <td valign="top">Specify where to find source files by <a
  59. href="../using.html#references">reference</a> to a PATH defined elsewhere.</td>
  60. <td align="center" valign="top">all</td>
  61. </tr>
  62. <tr>
  63. <td valign="top">sourcefiles</td>
  64. <td valign="top">Comma separated list of source files -- see also
  65. the nested <code>source</code> element.</td>
  66. <td align="center" valign="top">all</td>
  67. </tr>
  68. <tr>
  69. <td valign="top">destdir</td>
  70. <td valign="top">Destination directory for output files</td>
  71. <td align="center" valign="top">all</td>
  72. <td align="center" valign="top">Yes, unless a doclet has been specified.</td>
  73. </tr>
  74. <tr>
  75. <td valign="top">maxmemory</td>
  76. <td valign="top">Max amount of memory to allocate to the javadoc VM</td>
  77. <td align="center" valign="top">all</td>
  78. <td align="center" valign="top">No</td>
  79. </tr>
  80. <tr>
  81. <td valign="top">packagenames</td>
  82. <td valign="top">Comma separated list of package files (with terminating
  83. wildcard) -- see also the nested <code>package</code> element.</td>
  84. <td align="center" valign="top">all</td>
  85. <td align="center" valign="top">No</td>
  86. </tr>
  87. <tr>
  88. <td valign="top">packageList</td>
  89. <td valign="top">The name of a file containing the packages to process</td>
  90. <td align="center" valign="top">1.2+</td>
  91. <td align="center" valign="top">No</td>
  92. </tr>
  93. <tr>
  94. <td valign="top">classpath</td>
  95. <td valign="top">Specify where to find user class files</td>
  96. <td align="center" valign="top">all</td>
  97. <td align="center" valign="top">No</td>
  98. </tr>
  99. <tr>
  100. <td valign="top">Bootclasspath</td>
  101. <td valign="top">Override location of class files loaded by the bootstrap
  102. class loader</td>
  103. <td align="center" valign="top">1.2+</td>
  104. <td align="center" valign="top">No</td>
  105. </tr>
  106. <tr>
  107. <td valign="top">classpathref</td>
  108. <td valign="top">Specify where to find user class files by <a
  109. href="../using.html#references">reference</a> to a PATH defined elsewhere.</td>
  110. <td align="center" valign="top">all</td>
  111. <td align="center" valign="top">No</td>
  112. </tr>
  113. <tr>
  114. <td valign="top">bootclasspathref</td>
  115. <td valign="top">Override location of class files loaded by the
  116. bootstrap class loader by <a href="../using.html#references">reference</a> to a
  117. PATH defined elsewhere.</td>
  118. <td align="center" valign="top">1.2+</td>
  119. <td align="center" valign="top">No</td>
  120. </tr>
  121. <tr>
  122. <td valign="top">Extdirs</td>
  123. <td valign="top">Override location of installed extensions</td>
  124. <td align="center" valign="top">1.2+</td>
  125. <td align="center" valign="top">No</td>
  126. </tr>
  127. <tr>
  128. <td valign="top">Overview</td>
  129. <td valign="top">Read overview documentation from HTML file</td>
  130. <td align="center" valign="top">1.2+</td>
  131. <td align="center" valign="top">No</td>
  132. </tr>
  133. <tr>
  134. <td valign="top">access</td>
  135. <td valign="top">Access mode: one of <code>public</code>, <code>protected</code>,
  136. <code>package</code>, or <code>private</code></td>
  137. <td align="center" valign="top">all</td>
  138. <td align="center" valign="top">No (default <code>protected</code>)</td>
  139. </tr>
  140. <tr>
  141. <td valign="top">Public</td>
  142. <td valign="top">Show only public classes and members</td>
  143. <td align="center" valign="top">all</td>
  144. <td align="center" valign="top">No</td>
  145. </tr>
  146. <tr>
  147. <td valign="top">Protected</td>
  148. <td valign="top">Show protected/public classes and members (default)</td>
  149. <td align="center" valign="top">all</td>
  150. <td align="center" valign="top">No</td>
  151. </tr>
  152. <tr>
  153. <td valign="top">Package</td>
  154. <td valign="top">Show package/protected/public classes and members</td>
  155. <td align="center" valign="top">all</td>
  156. <td align="center" valign="top">No</td>
  157. </tr>
  158. <tr>
  159. <td valign="top">Private</td>
  160. <td valign="top">Show all classes and members</td>
  161. <td align="center" valign="top">all</td>
  162. <td align="center" valign="top">No</td>
  163. </tr>
  164. <tr>
  165. <td valign="top">Old</td>
  166. <td valign="top">Generate output using JDK 1.1 emulating doclet</td>
  167. <td align="center" valign="top">1.2</td>
  168. <td align="center" valign="top">No</td>
  169. </tr>
  170. <tr>
  171. <td valign="top">Verbose</td>
  172. <td valign="top">Output messages about what Javadoc is doing</td>
  173. <td align="center" valign="top">1.2+</td>
  174. <td align="center" valign="top">No</td>
  175. </tr>
  176. <tr>
  177. <td valign="top">Locale</td>
  178. <td valign="top">Locale to be used, e.g. en_US or en_US_WIN</td>
  179. <td align="center" valign="top">1.2+</td>
  180. <td align="center" valign="top">No</td>
  181. </tr>
  182. <tr>
  183. <td valign="top">Encoding</td>
  184. <td valign="top">Source file encoding name</td>
  185. <td align="center" valign="top">all</td>
  186. <td align="center" valign="top">No</td>
  187. </tr>
  188. <tr>
  189. <td valign="top">Version</td>
  190. <td valign="top">Include @version paragraphs</td>
  191. <td align="center" valign="top">all</td>
  192. <td align="center" valign="top">No</td>
  193. </tr>
  194. <tr>
  195. <td valign="top">Use</td>
  196. <td valign="top">Create class and package usage pages</td>
  197. <td align="center" valign="top">1.2+</td>
  198. <td align="center" valign="top">No</td>
  199. </tr>
  200. <tr>
  201. <td valign="top">Author</td>
  202. <td valign="top">Include @author paragraphs</td>
  203. <td align="center" valign="top">all</td>
  204. <td align="center" valign="top">No</td>
  205. </tr>
  206. <tr>
  207. <td valign="top">Splitindex</td>
  208. <td valign="top">Split index into one file per letter</td>
  209. <td align="center" valign="top">1.2+</td>
  210. <td align="center" valign="top">No</td>
  211. </tr>
  212. <tr>
  213. <td valign="top">Windowtitle</td>
  214. <td valign="top">Browser window title for the documentation (text)</td>
  215. <td align="center" valign="top">1.2+</td>
  216. <td align="center" valign="top">No</td>
  217. </tr>
  218. <tr>
  219. <td valign="top">Doctitle</td>
  220. <td valign="top">Include title for the package index(first) page (html-code)</td>
  221. <td align="center" valign="top">1.2+</td>
  222. <td align="center" valign="top">No</td>
  223. </tr>
  224. <tr>
  225. <td valign="top">Header</td>
  226. <td valign="top">Include header text for each page (html-code)</td>
  227. <td align="center" valign="top">1.2+</td>
  228. <td align="center" valign="top">No</td>
  229. </tr>
  230. <tr>
  231. <td valign="top">Footer</td>
  232. <td valign="top">Include footer text for each page (html-code)</td>
  233. <td align="center" valign="top">1.2+</td>
  234. <td align="center" valign="top">No</td>
  235. </tr>
  236. <tr>
  237. <td valign="top">bottom</td>
  238. <td valign="top">Include bottom text for each page (html-code)</td>
  239. <td align="center" valign="top">1.2+</td>
  240. <td align="center" valign="top">No</td>
  241. </tr>
  242. <tr>
  243. <td valign="top">link</td>
  244. <td valign="top">Create links to javadoc output at the given URL
  245. -- see also the nested <code>link</code> element.</td>
  246. <td align="center" valign="top">1.2+</td>
  247. <td align="center" valign="top">No</td>
  248. </tr>
  249. <tr>
  250. <td valign="top">linkoffline</td>
  251. <td valign="top">Link to docs at &lt;url&gt; using package list at
  252. &lt;url2&gt; - separate the URLs by using a space character -- see
  253. also the nested <code>link</code> element.</td>
  254. <td align="center" valign="top">1.2+</td>
  255. <td align="center" valign="top">No</td>
  256. </tr>
  257. <tr>
  258. <td valign="top">group</td>
  259. <td valign="top">Group specified packages together in overview
  260. page. The format is as described <a
  261. href="#groupattribute">below</a> -- see also the nested
  262. <code>group</code> element.</td>
  263. <td align="center" valign="top">1.2+</td>
  264. <td align="center" valign="top">No</td>
  265. </tr>
  266. <tr>
  267. <td valign="top">nodeprecated</td>
  268. <td valign="top">Do not include @deprecated information</td>
  269. <td align="center" valign="top">all</td>
  270. <td align="center" valign="top">No</td>
  271. </tr>
  272. <tr>
  273. <td valign="top">nodeprecatedlist</td>
  274. <td valign="top">Do not generate deprecated list</td>
  275. <td align="center" valign="top">1.2+</td>
  276. <td align="center" valign="top">No</td>
  277. </tr>
  278. <tr>
  279. <td valign="top">notree</td>
  280. <td valign="top">Do not generate class hierarchy</td>
  281. <td align="center" valign="top">all</td>
  282. <td align="center" valign="top">No</td>
  283. </tr>
  284. <tr>
  285. <td valign="top">noindex</td>
  286. <td valign="top">Do not generate index</td>
  287. <td align="center" valign="top">all</td>
  288. <td align="center" valign="top">No</td>
  289. </tr>
  290. <tr>
  291. <td valign="top">nohelp</td>
  292. <td valign="top">Do not generate help link</td>
  293. <td align="center" valign="top">1.2+</td>
  294. <td align="center" valign="top">No</td>
  295. </tr>
  296. <tr>
  297. <td valign="top">nonavbar</td>
  298. <td valign="top">Do not generate navigation bar</td>
  299. <td align="center" valign="top">1.2+</td>
  300. <td align="center" valign="top">No</td>
  301. </tr>
  302. <tr>
  303. <td valign="top">serialwarn</td>
  304. <td valign="top">Generate warning about @serial tag</td>
  305. <td align="center" valign="top">1.2+</td>
  306. <td align="center" valign="top">No</td>
  307. </tr>
  308. <tr>
  309. <td valign="top">helpfile</td>
  310. <td valign="top">Specifies the HTML help file to use</td>
  311. <td align="center" valign="top">1.2+</td>
  312. <td align="center" valign="top">No</td>
  313. </tr>
  314. <tr>
  315. <td valign="top">stylesheetfile</td>
  316. <td valign="top">Specifies the CSS stylesheet to use</td>
  317. <td align="center" valign="top">1.2+</td>
  318. <td align="center" valign="top">No</td>
  319. </tr>
  320. <tr>
  321. <td valign="top">charset</td>
  322. <td valign="top">Charset for cross-platform viewing of generated
  323. documentation</td>
  324. <td align="center" valign="top">1.2+</td>
  325. <td align="center" valign="top">No</td>
  326. </tr>
  327. <tr>
  328. <td valign="top">docencoding</td>
  329. <td valign="top">Output file encoding name</td>
  330. <td align="center" valign="top">all</td>
  331. <td align="center" valign="top">No</td>
  332. </tr>
  333. <tr>
  334. <td valign="top">doclet</td>
  335. <td valign="top">Specifies the class file that starts the doclet
  336. used in generating the documentation -- see also the nested
  337. <code>doclet</code> element.</td>
  338. <td align="center" valign="top">1.2+</td>
  339. <td align="center" valign="top">No</td>
  340. </tr>
  341. <tr>
  342. <td valign="top">docletpath</td>
  343. <td valign="top">Specifies the path to the doclet class file that is specified with the -doclet option.</td>
  344. <td align="center" valign="top">1.2+</td>
  345. <td align="center" valign="top">No</td>
  346. </tr>
  347. <tr>
  348. <td valign="top">docletpathref</td>
  349. <td valign="top">Specifies the path to the doclet class file that
  350. is specified with the -doclet option by <a
  351. href="../using.html#references">reference</a> to a PATH defined elsewhere.</td>
  352. <td align="center" valign="top">1.2+</td>
  353. <td align="center" valign="top">No</td>
  354. </tr>
  355. <tr>
  356. <td valign="top">additionalparam</td>
  357. <td valign="top">Lets you add additional parameters to the javadoc
  358. command line. Useful for doclets. Parameters containing spaces
  359. need to be quoted using &amp;quot; -- see also the nested
  360. <code>arg</code> element.</td>
  361. <td align="center" valign="top">all</td>
  362. <td align="center" valign="top">No</td>
  363. </tr>
  364. <tr>
  365. <td valign="top">failonerror</td>
  366. <td valign="top">Stop the buildprocess if the command exits with a
  367. returncode other than 0.</td>
  368. <td align="center" valign="top">all</td>
  369. <td align="center" valign="top">No</td>
  370. </tr>
  371. <tr>
  372. <td valign="top">excludepackagenames</td>
  373. <td valign="top">comma separated list of packages you don't want
  374. docs for -- see also the nested <code>excludepackage</code> element.</td>
  375. <td align="center" valign="top">all</td>
  376. <td valign="top" align="center">No</td>
  377. </tr>
  378. <tr>
  379. <td valign="top">defaultexcludes</td>
  380. <td valign="top">indicates whether default excludes should be used
  381. (<code>yes</code> | <code>no</code>); default excludes are used when omitted.</td>
  382. <td align="center" valign="top">all</td>
  383. <td valign="top" align="center">No</td>
  384. </tr>
  385. <tr>
  386. <td valign="top">useexternalfile</td>
  387. <td valign="top">indicates whether the sourcefile name specified
  388. in srcfiles or as nested source elements should be written to a
  389. temporary file to make the command line shorter. Also applies to
  390. the package names specified via the packagenames attribute or
  391. nested package elements.
  392. (<code>yes</code> | <code>no</code>). Default is no.</td>
  393. <td align="center" valign="top">1.2+</td>
  394. <td valign="top" align="center">No</td>
  395. </tr>
  396. <tr>
  397. <td valign="top">source</td>
  398. <td valign="top">Necessary to enable javadoc to handle assertions
  399. present in J2SE v 1.4 source code. Set this to &quot;1.4&quot; to
  400. documents code that compiles using <code>&quot;javac -source
  401. 1.4&quot;</code>.</td>
  402. <td align="center" valign="top">1.4+</td>
  403. <td align="center" valign="top">No</td>
  404. </tr>
  405. <tr>
  406. <td valign="top">linksource</td>
  407. <td valign="top">Generate hyperlinks to source files.
  408. <em>since Ant 1.6</em>.
  409. (<code>yes</code> | <code>no</code>). Default is no.</td>
  410. <td align="center" valign="top">1.4+</td>
  411. <td align="center" valign="top">No</td>
  412. </tr>
  413. <tr>
  414. <td valign="top">breakiterator</td>
  415. <td valign="top">Use the new breakiterator algorithm.
  416. <em>since Ant 1.6</em>.
  417. (<code>yes</code> | <code>no</code>). Default is no.</td>
  418. <td align="center" valign="top">1.4+</td>
  419. <td align="center" valign="top">No</td>
  420. </tr>
  421. <tr>
  422. <td valign="top">noqualifier</td>
  423. <td valign="top">Enables the <code>-noqualifier</code> argument -
  424. must be <code>all</code> or a colon separated list of packages.
  425. <em>since Ant 1.6</em>.</td>
  426. <td align="center" valign="top">1.4+</td>
  427. <td align="center" valign="top">No</td>
  428. </tr>
  429. </table>
  430. <h4><a name="groupattribute">Format of the group attribute</a></h4>
  431. <p>The arguments are comma-delimited. Each single argument is 2
  432. space-delimited strings, where the first one is the group's title and
  433. the second one a colon delimited list of packages.</p>
  434. <p>If you need to specify more than one group, or a group whose title
  435. contains a comma or a space character, using <a
  436. href="#groupelement">nested group elements</a> is highly
  437. recommended.</p>
  438. <p>E.g., </p>
  439. <pre> group=&quot;XSLT_Packages org.apache.xalan.xslt*,XPath_Packages org.apache.xalan.xpath*&quot;
  440. </pre>
  441. <h3>Parameters specified as nested elements</h3>
  442. <h4>packageset</h4>
  443. <p>A <a href="../CoreTypes/dirset.html">DirSet</a>. All matched
  444. directories that contain Java source files will be passed to javadoc
  445. as package names. Package names are created from the directory names
  446. by translating the directory separator into dots. Ant assumes the
  447. base directory of the packageset points to the root of a package
  448. hierarchy.</p>
  449. <p>The <code>packagenames</code>, <code>excludepackagenames</code> and
  450. <code>defaultexcludes</code> attributes of the task have no effect on
  451. the nested <code>&lt;packageset&gt;</code> elements.</p>
  452. <h4>fileset</h4>
  453. <p>A <a href="../CoreTypes/fileset.html">FileSet</a>. All matched
  454. files will be passed to javadoc as source files. Ant will
  455. automatically add the include pattern <code>**/*.java</code> to these
  456. filesets.</p>
  457. <p>Nested filesets can be used to document sources that are in the
  458. default package or if you want to exclude certain files from
  459. documentation. If you want to document all source files and don't use
  460. the default package, packagesets should be used instead as this
  461. increases javadocs performance.</p>
  462. <p>The <code>packagenames</code>, <code>excludepackagenames</code> and
  463. <code>defaultexcludes</code> attributes of the task have no effect on
  464. the nested <code>&lt;fileset&gt;</code> elements.</p>
  465. <h4>package</h4>
  466. <p>Same as one entry in the list given by <code>packagenames</code>.</p>
  467. <h5>Parameters</h5>
  468. <table width="60%" border="1" cellpadding="2" cellspacing="0">
  469. <tr>
  470. <td valign="top"><b>Attribute</b></td>
  471. <td valign="top"><b>Description</b></td>
  472. <td align="center" valign="top"><b>Required</b></td>
  473. </tr>
  474. <tr>
  475. <td valign="top">name</td>
  476. <td valign="top">The package name (may be a wildcard)</td>
  477. <td align="center" valign="top">Yes</td>
  478. </tr>
  479. </table>
  480. <h4>excludepackage</h4>
  481. <p>Same as one entry in the list given by <code>excludepackagenames</code>.</p>
  482. <h5>Parameters</h5>
  483. Same as for <code>package</code>.
  484. <h4>source</h4>
  485. <p>Same as one entry in the list given by <code>sourcefiles</code>.</p>
  486. <h5>Parameters</h5>
  487. <table width="60%" border="1" cellpadding="2" cellspacing="0">
  488. <tr>
  489. <td valign="top"><b>Attribute</b></td>
  490. <td valign="top"><b>Description</b></td>
  491. <td align="center" valign="top"><b>Required</b></td>
  492. </tr>
  493. <tr>
  494. <td valign="top">file</td>
  495. <td valign="top">The source file to document</td>
  496. <td align="center" valign="top">Yes</td>
  497. </tr>
  498. </table>
  499. <h4>doctitle</h4>
  500. <p>Same as the <code>doctitle</code> attribute, but you can nest text
  501. inside the element this way.</p>
  502. <h4>header</h4>
  503. <p>Similar to <code>&lt;doctitle&gt;</code>.</p>
  504. <h4>footer</h4>
  505. <p>Similar to <code>&lt;doctitle&gt;</code>.</p>
  506. <h4>bottom</h4>
  507. <p>Similar to <code>&lt;doctitle&gt;</code>.</p>
  508. <h4>link</h4>
  509. <p>Create link to javadoc output at the given URL. This performs the
  510. same role as the link and linkoffline attributes. You can use either
  511. syntax (or both at once), but with the nested elements you can easily
  512. specify multiple occurrences of the arguments.</p>
  513. <h5>Parameters</h5>
  514. <table width="60%" border="1" cellpadding="2" cellspacing="0">
  515. <tr>
  516. <td valign="top"><b>Attribute</b></td>
  517. <td valign="top"><b>Description</b></td>
  518. <td align="center" valign="top"><b>Required</b></td>
  519. </tr>
  520. <tr>
  521. <td valign="top">href</td>
  522. <td valign="top">The URL for the external documentation you wish to link to</td>
  523. <td align="center" valign="top">Yes</td>
  524. </tr>
  525. <tr>
  526. <td valign="top">offline</td>
  527. <td valign="top">True if this link is not available online at the time of
  528. generating the documentation</td>
  529. <td align="center" valign="top">No</td>
  530. </tr>
  531. <tr>
  532. <td valign="top">packagelistLoc</td>
  533. <td valign="top">The location to the directory containing the package-list file for
  534. the external documentation</td>
  535. <td align="center" valign="top">Only if the offline attribute is true</td>
  536. </tr>
  537. </table>
  538. <h4><a name="groupelement">group</a></h4>
  539. <p>Separates packages on the overview page into whatever groups you
  540. specify, one group per table. This performs the same role as the group
  541. attribute. You can use either syntax (or both at once), but with the
  542. nested elements you can easily specify multiple occurrences of the
  543. arguments.</p>
  544. <h5>Parameters</h5>
  545. <table width="60%" border="1" cellpadding="2" cellspacing="0">
  546. <tr>
  547. <td valign="top"><b>Attribute</b></td>
  548. <td valign="top"><b>Description</b></td>
  549. <td align="center" valign="top"><b>Required</b></td>
  550. </tr>
  551. <tr>
  552. <td valign="top">title</td>
  553. <td valign="top">Title of the group</td>
  554. <td align="center" valign="top">Yes, unless nested <code>&lt;title&gt;</code> given</td>
  555. </tr>
  556. <tr>
  557. <td valign="top">packages</td>
  558. <td valign="top">List of packages to include in that group. Multiple packages are separated with ':'.</td>
  559. <td align="center" valign="top">Yes, unless nested <code>&lt;package&gt;</code>s given</td>
  560. </tr>
  561. </table>
  562. <p>The title may be specified as a nested <code>&lt;title&gt;</code> element
  563. with text contents, and the packages may be listed with nested
  564. <code>&lt;package&gt;</code> elements as for the main task.</p>
  565. <h4>doclet</h4>
  566. <p>The doclet nested element is used to specify the doclet that javadoc will
  567. use to process the input source files. A number of the standard javadoc arguments
  568. are actually arguments of the standard doclet. If these are specified in the javadoc
  569. task's attributes, they will be passed to the doclet specified in the
  570. <code>&lt;doclet&gt;</code> nested element. Such attributes should only be specified,
  571. therefore, if they can be interpreted by the doclet in use.</p>
  572. <p>If the doclet requires additional parameters, these can be specified with
  573. <code>&lt;param&gt;</code> elements within the <code>&lt;doclet&gt;</code>
  574. element. These paramaters are restricted to simple strings. An example usage
  575. of the doclet element is shown below:</p>
  576. <pre> &lt;javadoc ... &gt;
  577. &lt;doclet name=&quot;theDoclet&quot;
  578. path=&quot;path/to/theDoclet&quot;&gt;
  579. &lt;param name=&quot;-foo&quot; value=&quot;foovalue&quot;/&gt;
  580. &lt;param name=&quot;-bar&quot; value=&quot;barvalue&quot;/&gt;
  581. &lt;/doclet&gt;
  582. &lt;/javadoc&gt;
  583. </pre>
  584. <h4><a name="tagelement">tag</a></h4>
  585. <p>The tag nested element is used to specify custom tags. This option
  586. is only available with Java 1.4.</p>
  587. <p>If you want to specify a standard tag using a nested tag element
  588. because you want to determine the order the tags are output, you must
  589. not set the description attribute for those tags.</p>
  590. <h5>Parameters</h5>
  591. <table width="60%" border="1" cellpadding="2" cellspacing="0">
  592. <tr>
  593. <td valign="top"><b>Attribute</b></td>
  594. <td valign="top"><b>Description</b></td>
  595. <td align="center" valign="top"><b>Required</b></td>
  596. </tr>
  597. <tr>
  598. <td valign="top">name</td>
  599. <td valign="top">Name of the tag (e.g. <code>todo</code>)</td>
  600. <td align="center" valign="top">Yes, unless the <code>dir</code> attribute is specified.</td>
  601. </tr>
  602. <tr>
  603. <td valign="top">description</td>
  604. <td valign="top">Description for tag (e.g. <code>To do:</code>)</td>
  605. <td align="center" valign="top">Yes, unless the <code>dir</code>
  606. attribute is specified or name is a standard tag.</td>
  607. </tr>
  608. <tr>
  609. <td valign="top">enabled</td>
  610. <td valign="top">Whether or not the tag is enabled (defaults to <code>true</code>)</td>
  611. <td align="center" valign="top">No</td>
  612. </tr>
  613. <tr>
  614. <td valign="top">scope</td>
  615. <td valign="top">Scope for the tag - the elements in which it can be used. This
  616. is a comma separated list of some of the elements: <code>overview</code>,
  617. <code>packages</code>, <code>types</code>, <code>constructors</code>,
  618. <code>methods</code>, <code>fields</code> or the default, <code>all</code>.</td>
  619. <td align="center" valign="top">No</td>
  620. </tr>
  621. <tr>
  622. <td valign="top">dir</td>
  623. <td valign="top">If this attribute is specified, this element will behave as an implicit
  624. <a href="../CoreTypes/fileset.html">fileset</a>. The files included by this fileset should
  625. contain each tag definition on a separate line, as described in the
  626. <a href="http://java.sun.com/j2se/1.4.1/docs/tooldocs/windows/javadoc.html#tag">javadoc reference guide</a>:
  627. <p/>
  628. <code>
  629. ejb.bean:t:"XDoclet EJB Tag"<br/>
  630. todo:a:"To Do"<br/>
  631. </code>
  632. <p/>
  633. Note: If this attribute is specified, all the other attributes in this
  634. element will be ignored.
  635. </td>
  636. <td align="center" valign="top">No</td>
  637. </tr>
  638. </table>
  639. <h4><a name="tagletelement">taglet</a></h4>
  640. <p>The taglet nested element is used to specify custom taglets. This option is
  641. only available with Java 1.4.</p>
  642. <h5>Parameters</h5>
  643. <table width="60%" border="1" cellpadding="2" cellspacing="0">
  644. <tr>
  645. <td valign="top"><b>Attribute</b></td>
  646. <td valign="top"><b>Description</b></td>
  647. <td align="center" valign="top"><b>Required</b></td>
  648. </tr>
  649. <tr>
  650. <td valign="top">name</td>
  651. <td valign="top">The name of the taglet class
  652. (e.g. <code>com.sun.tools.doclets.ToDoTaglet</code>)</td>
  653. <td align="center" valign="top">Yes</td>
  654. </tr>
  655. <tr>
  656. <td valign="top">path</td>
  657. <td valign="top">A path specifying the search path for the taglet class
  658. (e.g. <code>/home/taglets</code>).
  659. The path may also be specified by a nested &lt;path&gt; element</td>
  660. <td align="center" valign="top">No</td>
  661. </tr>
  662. </table>
  663. <h4>sourcepath, classpath and bootclasspath</h4>
  664. <p><code>Javadoc</code>'s <i>sourcepath</i>, <i>classpath</i> and
  665. <i>bootclasspath</i> attributes are <a href="../using.html#path">PATH like
  666. structure</a> and can also be set via nested <i>sourcepath</i>,
  667. <i>classpath</i> and <i>bootclasspath</i> elements
  668. respectively.</p>
  669. <h4>arg</h4>
  670. <p>Use nested <code>&lt;arg&gt;</code> to specify additional
  671. arguments. See <a href="../using.html#arg">Command line
  672. arguments</a>. <em>Since Ant 1.6</em></p>
  673. <h3>Example</h3>
  674. <pre> &lt;javadoc packagenames=&quot;com.dummy.test.*&quot;
  675. sourcepath=&quot;src&quot;
  676. excludepackagenames=&quot;com.dummy.test.doc-files.*&quot;
  677. defaultexcludes=&quot;yes&quot;
  678. destdir=&quot;docs/api&quot;
  679. author=&quot;true&quot;
  680. version=&quot;true&quot;
  681. use=&quot;true&quot;
  682. windowtitle=&quot;Test API&quot;&gt;
  683. &lt;doctitle&gt;&lt;![CDATA[&lt;h1&gt;Test&lt;/h1&gt;]]&gt;&lt;/doctitle&gt;
  684. &lt;bottom&gt;&lt;![CDATA[&lt;i&gt;Copyright &amp;#169; 2000 Dummy Corp. All Rights Reserved.&lt;/i&gt;]]&gt;&lt;/bottom&gt;
  685. &lt;tag name=&quot;todo&quot; scope=&quot;all&quot; description=&quot;To do:&quot; /&gt;
  686. &lt;group title=&quot;Group 1 Packages&quot; packages=&quot;com.dummy.test.a*&quot;/&gt;
  687. &lt;group title=&quot;Group 2 Packages&quot; packages=&quot;com.dummy.test.b*:com.dummy.test.c*&quot;/&gt;
  688. &lt;link offline=&quot;true&quot; href=&quot;http://java.sun.com/products/jdk/1.2/docs/api/&quot; packagelistLoc=&quot;C:\tmp&quot;/&gt;
  689. &lt;link href=&quot;http://developer.java.sun.com/developer/products/xml/docs/api/&quot;/&gt;
  690. &lt/javadoc&gt;</pre>
  691. <p>is the same as</p>
  692. <pre> &lt;javadoc
  693. destdir=&quot;docs/api&quot;
  694. author=&quot;true&quot;
  695. version=&quot;true&quot;
  696. use=&quot;true&quot;
  697. windowtitle=&quot;Test API&quot;&gt;
  698. &lt;packageset dir=&quot;src&quot; defaultexcludes=&quot;yes&quot;&gt;
  699. &lt;include name=&quot;com/dummy/test/**&quot; /&gt;
  700. &lt;exclude name=&quot;com/dummy/test/doc-files/**&quot;/&gt;
  701. &lt;/packageset&gt;
  702. &lt;doctitle&gt;&lt;![CDATA[&lt;h1&gt;Test&lt;/h1&gt;]]&gt;&lt;/doctitle&gt;
  703. &lt;bottom&gt;&lt;![CDATA[&lt;i&gt;Copyright &amp;#169; 2000 Dummy Corp. All Rights Reserved.&lt;/i&gt;]]&gt;&lt;/bottom&gt;
  704. &lt;tag name=&quot;todo&quot; scope=&quot;all&quot; description=&quot;To do:&quot; /&gt;
  705. &lt;group title=&quot;Group 1 Packages&quot; packages=&quot;com.dummy.test.a*&quot;/&gt;
  706. &lt;group title=&quot;Group 2 Packages&quot; packages=&quot;com.dummy.test.b*:com.dummy.test.c*&quot;/&gt;
  707. &lt;link offline=&quot;true&quot; href=&quot;http://java.sun.com/products/jdk/1.2/docs/api/&quot; packagelistLoc=&quot;C:\tmp&quot;/&gt;
  708. &lt;link href=&quot;http://developer.java.sun.com/developer/products/xml/docs/api/&quot;/&gt;
  709. &lt/javadoc&gt;</pre>
  710. <p>or</p>
  711. <pre> &lt;javadoc
  712. destdir=&quot;docs/api&quot;
  713. author=&quot;true&quot;
  714. version=&quot;true&quot;
  715. use=&quot;true&quot;
  716. windowtitle=&quot;Test API&quot;&gt;
  717. &lt;fileset dir=&quot;src&quot; defaultexcludes=&quot;yes&quot;&gt;
  718. &lt;include name=&quot;com/dummy/test/**&quot; /&gt;
  719. &lt;exclude name=&quot;com/dummy/test/doc-files/**&quot;/&gt;
  720. &lt;/fileset&gt;
  721. &lt;doctitle&gt;&lt;![CDATA[&lt;h1&gt;Test&lt;/h1&gt;]]&gt;&lt;/doctitle&gt;
  722. &lt;bottom&gt;&lt;![CDATA[&lt;i&gt;Copyright &amp;#169; 2000 Dummy Corp. All Rights Reserved.&lt;/i&gt;]]&gt;&lt;/bottom&gt;
  723. &lt;tag name=&quot;todo&quot; scope=&quot;all&quot; description=&quot;To do:&quot; /&gt;
  724. &lt;group title=&quot;Group 1 Packages&quot; packages=&quot;com.dummy.test.a*&quot;/&gt;
  725. &lt;group title=&quot;Group 2 Packages&quot; packages=&quot;com.dummy.test.b*:com.dummy.test.c*&quot;/&gt;
  726. &lt;link offline=&quot;true&quot; href=&quot;http://java.sun.com/products/jdk/1.2/docs/api/&quot; packagelistLoc=&quot;C:\tmp&quot;/&gt;
  727. &lt;link href=&quot;http://developer.java.sun.com/developer/products/xml/docs/api/&quot;/&gt;
  728. &lt/javadoc&gt;</pre>
  729. <hr>
  730. <p align="center">Copyright &copy; 2000-2003 Apache Software Foundation. All rights
  731. Reserved.</p>
  732. </body>
  733. </html>