aheritier 2004/09/26 06:47:13
Modified: javadoc/src/main/org/apache/maven/javadoc
JavadocWarningsTextToXml.java
javadoc/src/test/org/apache/maven/javadoc
JavadocWarningsTextToXmlTest.java
Added: javadoc/src/main/org/apache/maven/javadoc package.html
Log:
Fix checkstyle errors
Revision Changes Path
1.5 +54 -17
maven-plugins/javadoc/src/main/org/apache/maven/javadoc/JavadocWarningsTextToXml.java
Index: JavadocWarningsTextToXml.java
===================================================================
RCS file:
/home/cvs/maven-plugins/javadoc/src/main/org/apache/maven/javadoc/JavadocWarningsTextToXml.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- JavadocWarningsTextToXml.java 5 Sep 2004 21:00:34 -0000 1.4
+++ JavadocWarningsTextToXml.java 26 Sep 2004 13:47:13 -0000 1.5
@@ -1,5 +1,22 @@
package org.apache.maven.javadoc;
+/* ====================================================================
+ * Copyright 2001-2004 The Apache Software Foundation.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ====================================================================
+ */
+
import org.apache.commons.collections.set.ListOrderedSet;
import org.apache.commons.lang.StringEscapeUtils;
import org.apache.commons.lang.StringUtils;
@@ -85,7 +102,6 @@
*
* @throws IOException if an exception occurs opening, reading, or writing
* files
- * @throws IllegalArgumentException if arguments aren't correctly setted.
*/
public static void main(final String[] args)
throws IOException
@@ -108,17 +124,17 @@
* Sets the name of the input file. This file is expected to be a report
* generated by Javadoc.
*
- * @param inputFileName the input file name
+ * @param inputFileNameValue the input file name
*/
- public void setInputFileName(final String inputFileName)
+ public void setInputFileName(final String inputFileNameValue)
{
if (this.isVerbose())
{
- System.out.println("Setting input file name: '" + inputFileName
+ System.out.println("Setting input file name: '" + inputFileNameValue
+ "'");
}
- this.inputFileName = inputFileName;
+ this.inputFileName = inputFileNameValue;
}
/**
@@ -134,11 +150,11 @@
/**
* Sets the output encoding.
*
- * @param outputEncoding the output encoding
+ * @param outputEncodingValue the output encoding
*/
- public void setOutputEncoding(final String outputEncoding)
+ public void setOutputEncoding(final String outputEncodingValue)
{
- this.outputEncoding = outputEncoding;
+ this.outputEncoding = outputEncodingValue;
}
/**
@@ -154,17 +170,17 @@
/**
* Sets the output file name.
*
- * @param outputFileName the output file name
+ * @param outputFileNameValue the output file name
*/
- public void setOutputFileName(final String outputFileName)
+ public void setOutputFileName(final String outputFileNameValue)
{
if (this.isVerbose())
{
- System.out.println("Setting output file name: '" + outputFileName
+ System.out.println("Setting output file name: '" + outputFileNameValue
+ "'");
}
- this.outputFileName = outputFileName;
+ this.outputFileName = outputFileNameValue;
}
/**
@@ -180,11 +196,11 @@
/**
* Sets the verbose mode. <br>
*
- * @param verbose the verbose mode.
+ * @param verboseValue the verbose mode.
*/
- public void setVerbose(final boolean verbose)
+ public void setVerbose(final boolean verboseValue)
{
- this.verbose = verbose;
+ this.verbose = verboseValue;
if (this.isVerbose())
{
@@ -199,7 +215,6 @@
* reading or the output file cannot be opened for writing
* @throws IOException if an error occurs reading or writing
* @throws UnsupportedEncodingException if an unknown encoding was specified
- * @throws IllegalArgumentException If a needed property isn't setted.
*/
public void build()
throws FileNotFoundException, IOException, UnsupportedEncodingException
@@ -232,6 +247,11 @@
return verbose;
}
+ /**
+ * Build a Map from the javadoc report lines.
+ * @param input the lines
+ * @return the Map of files with javadoc errors.
+ */
private Map buildMap(final String[] input)
{
if (this.isVerbose())
@@ -308,6 +328,12 @@
return files;
}
+ /**
+ * Build the output on the disk.
+ * @param fileMap The map containing the results.
+ * @throws FileNotFoundException If the file cannot be created.
+ * @throws UnsupportedEncodingException If the encoding isn't supported.
+ */
private void buildOutput(final Map fileMap)
throws FileNotFoundException, UnsupportedEncodingException
{
@@ -327,6 +353,12 @@
out.close();
}
+ /**
+ * Extract warning lines from the javadoc result.
+ * @return a table of lines.
+ * @throws FileNotFoundException If the javadoc result can't be read.
+ * @throws IOException If there's a problem while reading the javadoc result.
+ */
private String[] readInput()
throws FileNotFoundException, IOException
{
@@ -361,6 +393,11 @@
return (String[]) lines.toArray(new String[lines.size()]);
}
+ /**
+ * Write the file map on the output
+ * @param fileMap The filemap to translate in XML.
+ * @param out The output to write.
+ */
private void writeOutput(final Map fileMap, final PrintWriter out)
{
if (this.isVerbose())
1.1
maven-plugins/javadoc/src/main/org/apache/maven/javadoc/package.html
Index: package.html
===================================================================
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<title>Package documentation</title>
<body><p>This package contains the Javadoc plugin classes.</p></body>
</html>
1.3 +1 -2
maven-plugins/javadoc/src/test/org/apache/maven/javadoc/JavadocWarningsTextToXmlTest.java
Index: JavadocWarningsTextToXmlTest.java
===================================================================
RCS file:
/home/cvs/maven-plugins/javadoc/src/test/org/apache/maven/javadoc/JavadocWarningsTextToXmlTest.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- JavadocWarningsTextToXmlTest.java 5 Sep 2004 21:00:34 -0000 1.2
+++ JavadocWarningsTextToXmlTest.java 26 Sep 2004 13:47:13 -0000 1.3
@@ -1,6 +1,5 @@
package org.apache.maven.javadoc;
-
/* ====================================================================
* Copyright 2001-2004 The Apache Software Foundation.
*
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]