FileDocCategorySizeDatePackage
PackageIndexWriter.javaAPI DocExample5717Wed Apr 19 11:17:12 BST 2000com.sun.tools.doclets.standard

PackageIndexWriter

public class PackageIndexWriter extends AbstractPackageIndexWriter
Generate the package index page "overview-summary.html" for the right-hand frame. A click on the package name on this page will update the same frame with the "pacakge-summary.html" file for the clicked package.
author
Atul M Dambalkar

Fields Summary
private RootDoc
root
Root of the program structure. Used for "overview" documentation.
private Map
groupPackageMap
Map representing the group of packages as specified on the command line.
private List
groupList
List to store the order groups as specified on the command line.
Constructors Summary
public PackageIndexWriter(String filename, RootDoc root)
Construct the PackageIndexWriter. Also constructs the grouping information as provided on the command line by "-group" option. Stores the order of groups specified by the user.

see
Group

        super(filename);
        this.root = root;
        groupPackageMap = Group.groupPackages(packages);
        groupList = Group.getGroupList();
    
Methods Summary
public static voidgenerate(com.sun.javadoc.RootDoc root)
Generate the package index page for the right-hand frame.

param
root the root of the doc tree.

        PackageIndexWriter packgen;
        String filename = "overview-summary.html";
        try {
            packgen = new PackageIndexWriter(filename, root);
            packgen.generatePackageIndexFile();
            packgen.close();
        } catch (IOException exc) {
 Standard.configuration().standardmessage.error("doclet.exception_encountered", 
                                                 exc.toString(), filename);
            throw new DocletAbortException();
        }
    
protected voidgenerateIndex()
Depending upon the grouping information and their titles, generate separate table indices for each package group.

      	for (int i = 0; i < groupList.size(); i++) {
	    String groupname = (String)groupList.get(i);
	    List list = (List)groupPackageMap.get(groupname);
            if (list != null && list.size() > 0) {
                printIndexContents((PackageDoc[])list.
                                       toArray(new PackageDoc[list.size()]),
                                    groupname);
            }
        }
    
protected voidprintIndexFooter()
Print Html closing tags for the table for this package index.

        tableEnd();
        p();
        space();
    
protected voidprintIndexHeader(java.lang.String text)
Print Html tags for the table for this package index.

        tableIndexSummary();
        tableHeaderStart("#CCCCFF");
        bold(text);
        tableHeaderEnd();
    
protected voidprintIndexRow(com.sun.javadoc.PackageDoc packagedoc)
Print each package in separate rows in the index table. Generate link to each package.

param
packagedoc Package to which link is to be generated.

        trBgcolorStyle("white", "TableRowColor");
        summaryRow(20); 
        bold();
        printPackageLink(packagedoc);
        boldEnd();
        summaryRowEnd(); 
        summaryRow(0); 
        printSummaryComment(packagedoc);
        summaryRowEnd(); 
        trEnd();
    
protected voidprintNavigationBarFooter()
Print the footer fornavigation bar. Also print the "-bottom" specified on command line, at the top of page.

        hr();
        navLinks(false);
        printBottom();
    
protected voidprintNavigationBarHeader()
Print the header for navigation bar. Also print the "-title" specified on command line, at the top of page.

        navLinks(true);
	hr();
        printConfigurationTitle();
    
protected voidprintOverview()
Call {@link #printOverviewComment()} and then genrate the tag information as provided in the file specified by the "-overview" option on the command line.

        printOverviewComment();
        generateTagInfo(root);
    
protected voidprintOverviewComment()
Print the overview comment as provided in the file specified by the "-overview" option on the command line.

        if (root.inlineTags().length > 0) {
            anchor("overview_description");
            p();
            printInlineComment(root); 
            p();
        }
    
protected voidprintOverviewHeader()
Print the overview summary comment for this documentation. Print one line summary at the top of the page and generate a link to the description, which is generated at the end of this page.

        if (root.inlineTags().length > 0) {
            printSummaryComment(root);
            p();
            bold(getText("doclet.See"));
            br();
            printNbsps();
            printHyperLink("", "overview_description",
                           getText("doclet.Description"), true);
            p();
        }