FileDocCategorySizeDatePackage
AbstractPackageIndexWriter.javaAPI DocExample3870Wed Apr 19 11:17:10 BST 2000com.sun.tools.doclets.standard

AbstractPackageIndexWriter

public abstract class AbstractPackageIndexWriter extends HtmlStandardWriter
Abstract class to generate the package index. The package index needs to be generated in Frame and Non-Frame format. This will be sub-classed by to generate frame-index as well as overview-index.
author
Atul M Dambalkar

Fields Summary
protected PackageDoc[]
packages
Array of Packages to be documented.
Constructors Summary
public AbstractPackageIndexWriter(String filename)
Constructor. Also initialises the packages variable.

param
filename Name of the package index file to be generated.

        super(filename);
        packages = Standard.configuration().packages;
    
Methods Summary
protected voidgenerateIndex()
Generate the frame or non-frame package index.

        printIndexContents(packages, "doclet.Package_Summary");
    
protected voidgeneratePackageIndexFile()
Generate the contants in the package index file. Call appropriate methods from the sub-class in order to generate Frame or Non Frame format.

        printHeader(getText("doclet.Window_Overview", 
                             Standard.configuration().windowtitle)); 
        printNavigationBarHeader();
        printOverviewHeader();

        generateIndex();

        printOverview();

        printNavigationBarFooter();
        printBodyHtmlEnd();
    
protected voidnavLinkContents()
Highlight "Overview" in the bold format, in the navigation bar as this is the overview page.

        navCellRevStart();
        fontStyle("NavBarFont1Rev");
        boldText("doclet.Overview");
        fontEnd();
        navCellEnd();
    
protected voidprintAllClassesPackagesLink()
Do nothing. This will be overridden in PackageIndexFrameWriter.

    
protected voidprintConfigurationTitle()
Print the doctitle, if it is specified on the command line.

        if (Standard.configuration().doctitle.length() > 0) {
            center();
            h2();
            print(Standard.configuration().doctitle);
            h2End();
            centerEnd();
        }
    
protected voidprintIndexContents(com.sun.javadoc.PackageDoc[] packages, java.lang.String text)
Generate code for package index contents. Call appropriate methods from the sub-classes.

param
pacakges Array of packages to be documented.
param
text String which will be used as the heading.

        if (packages.length > 0) {
            Arrays.sort(packages);
            printIndexHeader(text);
            printAllClassesPackagesLink();
            for(int i = 0; i < packages.length; i++) {
                PackageDoc packagedoc = packages[i];
                printIndexRow(packagedoc);
            }
            printIndexFooter();
        }
    
protected abstract voidprintIndexFooter()

protected abstract voidprintIndexHeader(java.lang.String text)

protected abstract voidprintIndexRow(com.sun.javadoc.PackageDoc pkg)

protected abstract voidprintNavigationBarFooter()

protected abstract voidprintNavigationBarHeader()

protected voidprintOverview()
Default to no overview, overwrite to add overview.

    
protected abstract voidprintOverviewHeader()