langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/ConstantsSummaryBuilder.java
changeset 40587 1c355ea550ed
parent 40303 96a1226aca18
child 42000 8b7412f7eecd
--- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/ConstantsSummaryBuilder.java	Wed Jul 05 22:07:34 2017 +0200
+++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/ConstantsSummaryBuilder.java	Mon Aug 22 16:32:40 2016 -0700
@@ -25,7 +25,6 @@
 
 package jdk.javadoc.internal.doclets.toolkit.builders;
 
-import java.io.*;
 import java.util.*;
 
 import javax.lang.model.element.Element;
@@ -35,6 +34,7 @@
 
 import jdk.javadoc.internal.doclets.toolkit.ConstantsSummaryWriter;
 import jdk.javadoc.internal.doclets.toolkit.Content;
+import jdk.javadoc.internal.doclets.toolkit.DocletException;
 import jdk.javadoc.internal.doclets.toolkit.util.VisibleMemberMap;
 
 
@@ -116,6 +116,7 @@
      *
      * @param context       the build context.
      * @param writer        the writer for the summary.
+     * @return the new ConstantsSummaryBuilder
      */
     public static ConstantsSummaryBuilder getInstance(Context context,
             ConstantsSummaryWriter writer) {
@@ -124,9 +125,10 @@
 
     /**
      * {@inheritDoc}
+     * @throws DocletException if there is a problem while building the documentation
      */
     @Override
-    public void build() throws IOException {
+    public void build() throws DocletException {
         if (writer == null) {
             //Doclet does not support this output.
             return;
@@ -147,8 +149,9 @@
      *
      * @param node the XML element that specifies which components to document
      * @param contentTree the content tree to which the documentation will be added
+     * @throws DocletException if there is a problem while building the documentation
      */
-    public void buildConstantSummary(XMLNode node, Content contentTree) throws Exception {
+    public void buildConstantSummary(XMLNode node, Content contentTree) throws DocletException {
         contentTree = writer.getHeader();
         buildChildren(node, contentTree);
         writer.addFooter(contentTree);
@@ -177,8 +180,9 @@
      *
      * @param node the XML element that specifies which components to document
      * @param contentTree the tree to which the summaries will be added
+     * @throws DocletException if there is a problem while building the documentation
      */
-    public void buildConstantSummaries(XMLNode node, Content contentTree) {
+    public void buildConstantSummaries(XMLNode node, Content contentTree) throws DocletException {
         printedPackageHeaders.clear();
         Content summariesTree = writer.getConstantSummaries();
         for (PackageElement aPackage : configuration.packages) {
@@ -211,8 +215,11 @@
      *
      * @param node the XML element that specifies which components to document
      * @param summariesTree the tree to which the class constant summary will be added
+     * @throws DocletException if there is a problem while building the documentation
+     *
      */
-    public void buildClassConstantSummary(XMLNode node, Content summariesTree) {
+    public void buildClassConstantSummary(XMLNode node, Content summariesTree)
+            throws DocletException {
         SortedSet<TypeElement> classes = !currentPackage.isUnnamed()
                 ? utils.getAllClasses(currentPackage)
                 : configuration.typeElementCatalog.allUnnamedClasses();