Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
2.7, 2.8, 2.8.1
-
None
-
None
-
Patch
Description
Javadoc:fix fixTags parameter doesn't support 'return' value
According to the docs (http://maven.apache.org/plugins/maven-javadoc-plugin/fix-mojo.html#fixTags) the fixTags parameter should be able to handle the following values:
- all (fix all Javadoc tags)
- author (fix only @author tag)
- version (fix only @version tag)
- since (fix only @since tag)
- param (fix only @param tag)
- return (fix only @return tag)
- throws (fix only @throws tag)
- link (fix only @link tag)
When Calling javadoc:fix version 2.8 or 2.7 with -DfixTags=return gives the following error:
Unrecognized 'return' for fixTags parameter. Ignored it!
Using 2.6 this works just fine. When looking at the following diff:
--- maven/plugins/trunk/maven-javadoc-plugin/src/main/java/org/apache/maven/plugin/javadoc/AbstractFixJavadocMojo.java 2011/04/25 13:38:09 1096478 +++ maven/plugins/trunk/maven-javadoc-plugin/src/main/java/org/apache/maven/plugin/javadoc/AbstractFixJavadocMojo.java 2011/04/30 18:59:02 1098139 @@ -491,10 +491,8 @@ for ( int j = 0; j < split.length; j++ ) { String s = split[j].trim(); - if ( FIX_TAGS_ALL.equalsIgnoreCase( s.trim() ) || AUTHOR_TAG.equalsIgnoreCase( s.trim() ) - || VERSION_TAG.equalsIgnoreCase( s.trim() ) || SINCE_TAG.equalsIgnoreCase( s.trim() ) - || PARAM_TAG.equalsIgnoreCase( s.trim() ) || RETURN_TAG.equalsIgnoreCase( s.trim() ) - || THROWS_TAG.equalsIgnoreCase( s.trim() ) ) + if ( JavadocUtil.equalsIgnoreCase( s, FIX_TAGS_ALL, AUTHOR_TAG, VERSION_TAG, SINCE_TAG, PARAM_TAG, + THROWS_TAG ) ) { filtered.add( s ); }
the functionality seems to be broken since revision 1098139. I added a patch which restores the functionality.