src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractPackageIndexWriter.java

Print this page

        

@@ -21,20 +21,25 @@
  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  * or visit www.oracle.com if you need additional information or have any
  * questions.
  */
 
-package com.sun.tools.doclets.formats.html;
+package jdk.javadoc.internal.doclets.formats.html;
 
 import java.io.*;
 import java.util.*;
 
-import com.sun.javadoc.*;
-import com.sun.tools.doclets.formats.html.markup.*;
-import com.sun.tools.doclets.internal.toolkit.*;
-import com.sun.tools.doclets.internal.toolkit.util.DocPath;
+import javax.lang.model.element.PackageElement;
 
+import jdk.javadoc.internal.doclets.formats.html.markup.HtmlConstants;
+import jdk.javadoc.internal.doclets.formats.html.markup.HtmlStyle;
+import jdk.javadoc.internal.doclets.formats.html.markup.HtmlTag;
+import jdk.javadoc.internal.doclets.formats.html.markup.HtmlTree;
+import jdk.javadoc.internal.doclets.formats.html.markup.RawHtml;
+import jdk.javadoc.internal.doclets.toolkit.Content;
+import jdk.javadoc.internal.doclets.toolkit.util.DocPath;
+
 /**
  * Abstract class to generate the overview files in
  * Frame and Non-Frame format. This will be sub-classed by to
  * generate overview-frame.html as well as overview-summary.html.
  *

@@ -49,11 +54,11 @@
 public abstract class AbstractPackageIndexWriter extends HtmlDocletWriter {
 
     /**
      * A Set of Packages to be documented.
      */
-    protected SortedSet<PackageDoc> packages;
+    protected SortedSet<PackageElement> packages;
 
     /**
      * Constructor. Also initializes the packages variable.
      *
      * @param configuration  The current configuration

@@ -92,11 +97,11 @@
      * @param packages a collection of packagedoc objects
      * @param text caption for the table
      * @param tableSummary summary for the table
      * @param body the document tree to which the packages list will be added
      */
-    protected abstract void addPackagesList(Collection<PackageDoc> packages, String text,
+    protected abstract void addPackagesList(Collection<PackageElement> packages, String text,
             String tableSummary, Content body);
 
     /**
      * Generate and prints the contents in the package index file. Call appropriate
      * methods from the sub-class in order to generate Frame or Non

@@ -144,28 +149,21 @@
      * @param packages a collection of packages to be documented
      * @param text string which will be used as the heading
      * @param tableSummary summary for the table
      * @param body the document tree to which the index contents will be added
      */
-    protected void addIndexContents(Collection<PackageDoc> packages, String text,
+    protected void addIndexContents(Collection<PackageElement> packages, String text,
             String tableSummary, Content body) {
         if (!packages.isEmpty()) {
             HtmlTree htmlTree = (configuration.allowTag(HtmlTag.NAV))
                     ? HtmlTree.NAV()
                     : new HtmlTree(HtmlTag.DIV);
             htmlTree.addStyle(HtmlStyle.indexNav);
             HtmlTree ul = new HtmlTree(HtmlTag.UL);
             addAllClassesLink(ul);
-            if (configuration.showProfiles) {
-                addAllProfilesLink(ul);
-            }
             htmlTree.addContent(ul);
             body.addContent(htmlTree);
-            if (configuration.showProfiles && configuration.profilePackages.size() > 0) {
-                Content profileSummary = configuration.getResource("doclet.Profiles");
-                addProfilesList(profileSummary, body);
-            }
             addPackagesList(packages, text, tableSummary, body);
         }
     }
 
     /**

@@ -199,23 +197,6 @@
      *
      * @param div the document tree to which the all classes link will be added
      */
     protected void addAllClassesLink(Content div) {
     }
-
-    /**
-     * Do nothing. This will be overridden.
-     *
-     * @param div the document tree to which the all profiles link will be added
-     */
-    protected void addAllProfilesLink(Content div) {
-    }
-
-    /**
-     * Do nothing. This will be overridden.
-     *
-     * @param profileSummary the profile summary heading
-     * @param body the content tree to which the profiles list will be added
-     */
-    protected void addProfilesList(Content profileSummary, Content body) {
-    }
 }