Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Explain maven javadoc plugin empty <p> tag error

Tags:

java

maven

I'm trying to build javadocs for my project and it gives me following error:

 [ERROR] /home/kshitiz/Documents/workspaces/ggts/log4j-weblayout/src/main/java/in/ksharma/weblayout/WebAppender.java:25: warning: empty <p> tag
 [ERROR] * <p>
 [ERROR] ^
 [ERROR] /home/kshitiz/Documents/workspaces/ggts/log4j-weblayout/src/main/java/in/ksharma/weblayout/WebAppender.java:30: error: unexpected end tag: </p>

The class in question has this Javadoc:

/**
 * <p>
 * Appender to allow logging to multiple files. Utilizes the roll over and
 * appending functionality of the FileRollingAppender.
 * 
 * Exceptions are stored in small HTML file called snippet. We use several small
 * HTML files instead of one large one due to performance reasons.
 * </p>
 * 
 * <p>
 * <h1>Usage:</h1>
 * It supports the same set of configuration options as
 * <code>org.apache.log4j.RollingFileAppender</code> Consult log4j documentation
 * for full list of options.
 * </p>
 * 
 * @author Kshitiz Sharma
 */

The

tag is not empty. What is wrong with this javadoc?

like image 680
Kshitiz Sharma Avatar asked Sep 28 '22 17:09

Kshitiz Sharma


1 Answers

The message is misleading. It says <p> is empty but the real issue is that it doesn't like <h> tags nested inside <p>.

If you want to emphasize text inside a paragraph try using <em> instead.

like image 51
Kshitiz Sharma Avatar answered Oct 06 '22 19:10

Kshitiz Sharma