Permalink
Browse files

Fix JavaDoc problems reported by JDK 8.

  • Loading branch information...
1 parent 6396bb4 commit 57f7cf06888f1e34f9ab2e3129c3d433826ecbe1 @marchof marchof committed Feb 24, 2013
Showing with 79 additions and 13 deletions.
  1. +1 −0 jacoco-maven-plugin/src/org/jacoco/maven/BundleCreator.java
  2. +5 −4 jacoco-maven-plugin/src/org/jacoco/maven/FileFilter.java
  3. +1 −0 org.jacoco.ant/src/org/jacoco/ant/AbstractCoverageTask.java
  4. +5 −0 org.jacoco.core/src/org/jacoco/core/analysis/Analyzer.java
  5. +2 −0 org.jacoco.core/src/org/jacoco/core/data/ExecutionDataReader.java
  6. +2 −0 org.jacoco.core/src/org/jacoco/core/data/ExecutionDataWriter.java
  7. +1 −0 org.jacoco.core/src/org/jacoco/core/internal/ContentTypeDetector.java
  8. +2 −1 org.jacoco.core/src/org/jacoco/core/internal/data/CompactDataInput.java
  9. +2 −0 org.jacoco.core/src/org/jacoco/core/internal/data/CompactDataOutput.java
  10. +4 −3 org.jacoco.core/src/org/jacoco/core/runtime/AgentOptions.java
  11. +1 −0 org.jacoco.core/src/org/jacoco/core/runtime/RemoteControlReader.java
  12. +1 −0 org.jacoco.report/src/org/jacoco/report/FileMultiReportOutput.java
  13. +7 −0 org.jacoco.report/src/org/jacoco/report/internal/AbstractGroupVisitor.java
  14. +4 −0 org.jacoco.report/src/org/jacoco/report/internal/html/HTMLGroupVisitor.java
  15. +5 −0 org.jacoco.report/src/org/jacoco/report/internal/html/page/BundlePage.java
  16. +4 −0 org.jacoco.report/src/org/jacoco/report/internal/html/page/ClassPage.java
  17. +4 −0 org.jacoco.report/src/org/jacoco/report/internal/html/page/GroupPage.java
  18. +1 −1 org.jacoco.report/src/org/jacoco/report/internal/html/page/NodePage.java
  19. +5 −0 org.jacoco.report/src/org/jacoco/report/internal/html/page/PackagePage.java
  20. +1 −0 org.jacoco.report/src/org/jacoco/report/internal/html/page/ReportPage.java
  21. +7 −1 org.jacoco.report/src/org/jacoco/report/internal/html/page/SessionsPage.java
  22. +9 −3 org.jacoco.report/src/org/jacoco/report/internal/html/page/SourceFilePage.java
  23. +1 −0 org.jacoco.report/src/org/jacoco/report/internal/html/page/TablePage.java
  24. +4 −0 org.jacoco.report/src/org/jacoco/report/internal/xml/XMLCoverageWriter.java
@@ -51,6 +51,7 @@ public BundleCreator(final MavenProject project, final FileFilter fileFilter) {
* the execution data.
* @return the coverage data.
* @throws IOException
+ * if class files can't be read
*/
public IBundleCoverage createBundle(
final ExecutionDataStore executionDataStore) throws IOException {
@@ -12,14 +12,14 @@
*******************************************************************************/
package org.jacoco.maven;
-import org.apache.commons.collections.CollectionUtils;
-import org.codehaus.plexus.util.FileUtils;
-import org.codehaus.plexus.util.StringUtils;
-
import java.io.File;
import java.io.IOException;
import java.util.List;
+import org.apache.commons.collections.CollectionUtils;
+import org.codehaus.plexus.util.FileUtils;
+import org.codehaus.plexus.util.StringUtils;
+
/**
* A file filter using includes/excludes patterns.
*/
@@ -51,6 +51,7 @@ public FileFilter(final List<String> includes, final List<String> excludes) {
* the directory to scan
* @return a list of files
* @throws IOException
+ * if file system access fails
*/
@SuppressWarnings("unchecked")
public List<String> getFileNames(final File directory) throws IOException {
@@ -166,6 +166,7 @@ public void setAddress(final String address) {
* to when the output method is tcp client. Default is <code>6300</code>
*
* @param port
+ * port to bind to or connect to
*/
public void setPort(final int port) {
agentOptions.setPort(port);
@@ -110,6 +110,7 @@ public void analyzeClass(final byte[] buffer) {
* @param input
* stream to read class definition from
* @throws IOException
+ * if the stream can't be read
*/
public void analyzeClass(final InputStream input) throws IOException {
analyzeClass(new ClassReader(input));
@@ -123,6 +124,7 @@ public void analyzeClass(final InputStream input) throws IOException {
* ZIP archive data
* @return number of class files found
* @throws IOException
+ * if the stream can't be read
*/
public int analyzeArchive(final InputStream input) throws IOException {
final ZipInputStream zip = new ZipInputStream(input);
@@ -147,6 +149,7 @@ public int analyzeArchive(final InputStream input) throws IOException {
* input data
* @return number of class files found
* @throws IOException
+ * if the stream can't be read
*/
public int analyzeAll(final InputStream input) throws IOException {
final ContentTypeDetector detector = new ContentTypeDetector(input);
@@ -170,6 +173,7 @@ public int analyzeAll(final InputStream input) throws IOException {
* file or folder to look for class files
* @return number of class files found
* @throws IOException
+ * if the file can't be read
*/
public int analyzeAll(final File file) throws IOException {
int count = 0;
@@ -200,6 +204,7 @@ public int analyzeAll(final File file) throws IOException {
* entries
* @return number of class files found
* @throws IOException
+ * if a file can't be read
*/
public int analyzeAll(final String path, final File basedir)
throws IOException {
@@ -49,6 +49,7 @@ public ExecutionDataReader(final InputStream input) {
* Sets an listener for session information.
*
* @param visitor
+ * visitor to retrieve session info events
*/
public void setSessionInfoVisitor(final ISessionInfoVisitor visitor) {
this.sessionInfoVisitor = visitor;
@@ -58,6 +59,7 @@ public void setSessionInfoVisitor(final ISessionInfoVisitor visitor) {
* Sets an listener for execution data.
*
* @param visitor
+ * visitor to retrieve execution data events
*/
public void setExecutionDataVisitor(final IExecutionDataVisitor visitor) {
this.executionDataVisitor = visitor;
@@ -60,6 +60,7 @@ public ExecutionDataWriter(final OutputStream output) throws IOException {
* Writes an file header to identify the stream and its protocol version.
*
* @throws IOException
+ * if the header can't be written
*/
private void writeHeader() throws IOException {
out.writeByte(BLOCK_HEADER);
@@ -71,6 +72,7 @@ private void writeHeader() throws IOException {
* Flushes the underlying stream.
*
* @throws IOException
+ * if the underlying stream can't be flushed
*/
public void flush() throws IOException {
out.flush();
@@ -45,6 +45,7 @@
* @param in
* input to read the header from
* @throws IOException
+ * if the stream can't be read
*/
public ContentTypeDetector(final InputStream in) throws IOException {
if (in.markSupported()) {
@@ -38,7 +38,7 @@ public CompactDataInput(final InputStream in) {
*
* @return read value
* @throws IOException
- * might be thrown by the underlying stream
+ * if thrown by the underlying stream
*/
public int readVarInt() throws IOException {
final int value = 0xFF & readByte();
@@ -53,6 +53,7 @@ public int readVarInt() throws IOException {
*
* @return boolean array
* @throws IOException
+ * if thrown by the underlying stream
*/
public boolean[] readBooleanArray() throws IOException {
final boolean[] value = new boolean[readVarInt()];
@@ -41,6 +41,7 @@ public CompactDataOutput(final OutputStream out) {
* @param value
* value to write
* @throws IOException
+ * if thrown by the underlying stream
*/
public void writeVarInt(final int value) throws IOException {
if ((value & 0xFFFFFF80) == 0) {
@@ -58,6 +59,7 @@ public void writeVarInt(final int value) throws IOException {
* @param value
* boolean array
* @throws IOException
+ * if thrown by the underlying stream
*/
public void writeBooleanArray(final boolean[] value) throws IOException {
writeVarInt(value.length);
@@ -82,8 +82,7 @@
public static final String DUMPONEXIT = "dumponexit";
/**
- * Specifies the output mode. Default is
- * <code>{@link OutputMode#file}</code>.
+ * Specifies the output mode. Default is {@link OutputMode#file}.
*
* @see OutputMode#file
* @see OutputMode#tcpserver
@@ -388,6 +387,7 @@ public int getPort() {
* or the port to connect to when output is <code>tcpclient</code>
*
* @param port
+ * port to listen on or connect to
*/
public void setPort(final int port) {
validatePort(port);
@@ -407,7 +407,8 @@ public String getAddress() {
/**
* Sets the hostname or IP address to listen to when output is
- * <code>tcpserver</cose> or connect to when output is <code>tcpclient</code>
+ * <code>tcpserver</code> or connect to when output is
+ * <code>tcpclient</code>
*
* @param address
* Hostname or IP address
@@ -52,6 +52,7 @@ protected boolean readBlock(final byte blockid) throws IOException {
* Sets an listener for agent commands.
*
* @param visitor
+ * visitor to retrieve agent commands
*/
public void setRemoteCommandVisitor(final IRemoteCommandVisitor visitor) {
this.remoteCommandVisitor = visitor;
@@ -31,6 +31,7 @@
* Creates a new instance for document output in the given base directory.
*
* @param basedir
+ * base directory
*/
public FileMultiReportOutput(final File basedir) {
this.basedir = basedir;
@@ -51,8 +51,11 @@ public final void visitBundle(final IBundleCoverage bundle,
* Called to handle the given bundle in a specific way.
*
* @param bundle
+ * analyzed bundle
* @param locator
+ * source locator
* @throws IOException
+ * if the report can't be written
*/
protected abstract void handleBundle(IBundleCoverage bundle,
ISourceFileLocator locator) throws IOException;
@@ -68,8 +71,10 @@ public final IReportGroupVisitor visitGroup(final String name)
* Called to handle a group with the given name in a specific way.
*
* @param name
+ * name of the group
* @return created child group
* @throws IOException
+ * if the report can't be written
*/
protected abstract AbstractGroupVisitor handleGroup(final String name)
throws IOException;
@@ -78,6 +83,7 @@ protected abstract AbstractGroupVisitor handleGroup(final String name)
* Must be called at the end of every group.
*
* @throws IOException
+ * if the report can't be written
*/
public final void visitEnd() throws IOException {
finalizeLastChild();
@@ -88,6 +94,7 @@ public final void visitEnd() throws IOException {
* Called to handle the end of this group in a specific way.
*
* @throws IOException
+ * if the report can't be written
*/
protected abstract void handleEnd() throws IOException;
@@ -38,9 +38,13 @@
* Create a new group handler.
*
* @param parent
+ * optional hierarchical parent
* @param folder
+ * base folder for this group
* @param context
+ * settings context
* @param name
+ * group name
*/
public HTMLGroupVisitor(final ReportPage parent,
final ReportOutputFolder folder, final IHTMLReportContext context,
@@ -34,10 +34,15 @@
* Creates a new visitor in the given context.
*
* @param bundle
+ * coverage date for the bundle
* @param parent
+ * optional hierarchical parent
* @param locator
+ * source locator
* @param folder
+ * base folder for this bundle
* @param context
+ * settings context
*/
public BundlePage(final IBundleCoverage bundle, final ReportPage parent,
final ISourceFileLocator locator, final ReportOutputFolder folder,
@@ -31,11 +31,15 @@
* Creates a new visitor in the given context.
*
* @param classNode
+ * coverage data for this class
* @param parent
+ * optional hierarchical parent
* @param sourcePage
* corresponding source page or <code>null</code>
* @param folder
+ * base folder to create this page in
* @param context
+ * settings context
*/
public ClassPage(final IClassCoverage classNode, final ReportPage parent,
final ILinkable sourcePage, final ReportOutputFolder folder,
@@ -25,9 +25,13 @@
* Creates a new visitor in the given context.
*
* @param node
+ * corresponding coverage data
* @param parent
+ * optional hierarchical parent
* @param folder
+ * base folder to create this page in
* @param context
+ * settings context
*/
public GroupPage(final ICoverageNode node, final ReportPage parent,
final ReportOutputFolder folder, final IHTMLReportContext context) {
@@ -37,7 +37,7 @@
* @param parent
* optional hierarchical parent
* @param folder
- * base folder to create this report in
+ * base folder to create this page in
* @param context
* settings context
*/
@@ -36,10 +36,15 @@
* Creates a new visitor in the given context.
*
* @param node
+ * coverage data for this package
* @param parent
+ * optional hierarchical parent
* @param locator
+ * source locator
* @param folder
+ * base folder to create this page in
* @param context
+ * settings context
*/
public PackagePage(final IPackageCoverage node, final ReportPage parent,
final ISourceFileLocator locator, final ReportOutputFolder folder,
@@ -68,6 +68,7 @@ protected final boolean isRootPage() {
* must be called at most once.
*
* @throws IOException
+ * if the page can't be written
*/
public void render() throws IOException {
final HTMLDocument doc = new HTMLDocument(
@@ -56,11 +56,17 @@
* Creates a new page page to display session information.
*
* @param sessionInfos
+ * session info objects
* @param executionData
+ * execution data objects
* @param index
+ * index for cross-linking
* @param parent
+ * optional hierarchical parent
* @param folder
+ * base folder to create this page in
* @param context
+ * settings context
*/
public SessionsPage(final List<SessionInfo> sessionInfos,
final Collection<ExecutionData> executionData,
@@ -70,7 +76,7 @@ public SessionsPage(final List<SessionInfo> sessionInfos,
this.sessionInfos = sessionInfos;
this.executionData = new ArrayList<ExecutionData>(executionData);
this.index = index;
- dateFormat = DateFormat.getDateTimeInstance(DateFormat.DEFAULT,
+ this.dateFormat = DateFormat.getDateTimeInstance(DateFormat.DEFAULT,
DateFormat.DEFAULT, context.getLocale());
final ILanguageNames names = context.getLanguageNames();
Collections.sort(this.executionData, new Comparator<ExecutionData>() {
@@ -16,7 +16,7 @@
import java.io.IOException;
import java.io.Reader;
-import org.jacoco.core.analysis.ISourceFileCoverage;
+import org.jacoco.core.analysis.ISourceNode;
import org.jacoco.report.internal.ReportOutputFolder;
import org.jacoco.report.internal.html.HTMLElement;
import org.jacoco.report.internal.html.IHTMLReportContext;
@@ -26,7 +26,7 @@
* Page showing the content of a source file with numbered and highlighted
* source lines.
*/
-public class SourceFilePage extends NodePage<ISourceFileCoverage> {
+public class SourceFilePage extends NodePage<ISourceNode> {
private final Reader sourceReader;
@@ -36,13 +36,19 @@
* Creates a new page with given information.
*
* @param sourceFileNode
+ * coverage data for this source file
* @param sourceReader
+ * reader for the source code
* @param tabWidth
+ * number of character per tab
* @param parent
+ * optional hierarchical parent
* @param folder
+ * base folder for this page
* @param context
+ * settings context
*/
- public SourceFilePage(final ISourceFileCoverage sourceFileNode,
+ public SourceFilePage(final ISourceNode sourceFileNode,
final Reader sourceReader, final int tabWidth,
final ReportPage parent, final ReportOutputFolder folder,
final IHTMLReportContext context) {
Oops, something went wrong.

0 comments on commit 57f7cf0

Please sign in to comment.