包文档

Version >= Java SE 5

可以使用名为 package-info.java 的文件在 Javadocs 中创建包级文档。此文件必须格式如下。前导空格和星号可选,通常出现在每一行中,以便格式化

/**
 * Package documentation goes here; any documentation before the first period will 
 * be used as a summary.
 *
 * It is common practice to leave a blank line between the summary and the rest
 * of the documentation; use this space to describe the package in as much detail
 * as is appropriate.
 * 
 * Inline tags such as {@code code here}, {@link reference.to.other.Documentation},
 * and {@literal text here} can be used in this documentation.
 */
package com.example.foo;

// The rest of the file must be empty.

在上面的例子中,你必须将这个文件 package-info.java 放在 Java 包 com.example.foo 的文件夹中。