/** * Get the header for the package use listing. * * @return a content tree representing the package use header */ protected Content getPackageUseHeader() { String packageText = configuration.getText("doclet.Package"); String name = pkgdoc.name(); String title = configuration.getText("doclet.Window_ClassUse_Header", packageText, name); Content bodyTree = getBody(true, getWindowTitle(title)); addTop(bodyTree); addNavLinks(true, bodyTree); ContentBuilder headContent = new ContentBuilder(); headContent.addContent(getResource("doclet.ClassUse_Title", packageText)); headContent.addContent(new HtmlTree(HtmlTag.BR)); headContent.addContent(name); Content heading = HtmlTree.HEADING(HtmlConstants.TITLE_HEADING, true, HtmlStyle.title, headContent); Content div = HtmlTree.DIV(HtmlStyle.header, heading); bodyTree.addContent(div); return bodyTree; }
/** * Get the header for the class use Listing. * * @return a content tree representing the class use header */ protected Content getClassUseHeader() { String cltype = configuration.getText(classdoc.isInterface() ? "doclet.Interface" : "doclet.Class"); String clname = classdoc.qualifiedName(); String title = configuration.getText("doclet.Window_ClassUse_Header", cltype, clname); Content bodyTree = getBody(true, getWindowTitle(title)); addTop(bodyTree); addNavLinks(true, bodyTree); ContentBuilder headContent = new ContentBuilder(); headContent.addContent(getResource("doclet.ClassUse_Title", cltype)); headContent.addContent(new HtmlTree(HtmlTag.BR)); headContent.addContent(clname); Content heading = HtmlTree.HEADING(HtmlConstants.CLASS_PAGE_HEADING, true, HtmlStyle.title, headContent); Content div = HtmlTree.DIV(HtmlStyle.header, heading); bodyTree.addContent(div); return bodyTree; }