< prev index next >

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

Print this page
rev 47482 : 8190295: Introduce a new Table builder class
rev 47486 : 8190821: Introduce a new Links builder class

*** 45,54 **** --- 45,55 ---- import jdk.javadoc.internal.doclets.formats.html.markup.ContentBuilder; 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.Links; import jdk.javadoc.internal.doclets.formats.html.markup.StringContent; import jdk.javadoc.internal.doclets.toolkit.Content; import jdk.javadoc.internal.doclets.toolkit.util.ClassTree; import jdk.javadoc.internal.doclets.toolkit.util.ClassUseMapper; import jdk.javadoc.internal.doclets.toolkit.util.DocFileIOException;
*** 346,356 **** */ protected void addClassList(Content contentTree) { HtmlTree ul = new HtmlTree(HtmlTag.UL); ul.setStyle(HtmlStyle.blockList); for (PackageElement pkg : pkgSet) { ! Content markerAnchor = getMarkerAnchor(getPackageAnchorName(pkg)); HtmlTree htmlTree = (configuration.allowTag(HtmlTag.SECTION)) ? HtmlTree.SECTION(markerAnchor) : HtmlTree.LI(HtmlStyle.blockList, markerAnchor); Content link = contents.getContent("doclet.ClassUse_Uses.of.0.in.1", getLink(new LinkInfoImpl(configuration, LinkInfoImpl.Kind.CLASS_USE_HEADER, --- 347,357 ---- */ protected void addClassList(Content contentTree) { HtmlTree ul = new HtmlTree(HtmlTag.UL); ul.setStyle(HtmlStyle.blockList); for (PackageElement pkg : pkgSet) { ! Content markerAnchor = links.createAnchor(getPackageAnchorName(pkg)); HtmlTree htmlTree = (configuration.allowTag(HtmlTag.SECTION)) ? HtmlTree.SECTION(markerAnchor) : HtmlTree.LI(HtmlStyle.blockList, markerAnchor); Content link = contents.getContent("doclet.ClassUse_Uses.of.0.in.1", getLink(new LinkInfoImpl(configuration, LinkInfoImpl.Kind.CLASS_USE_HEADER,
*** 375,385 **** * @param pkg the package that uses the given class * @param table the table to which the package use information will be added */ protected void addPackageUse(PackageElement pkg, Table table) { Content pkgLink = ! getHyperLink(getPackageAnchorName(pkg), new StringContent(utils.getPackageName(pkg))); Content summary = new ContentBuilder(); addSummaryComment(pkg, summary); table.addRow(pkgLink, summary); } --- 376,386 ---- * @param pkg the package that uses the given class * @param table the table to which the package use information will be added */ protected void addPackageUse(PackageElement pkg, Table table) { Content pkgLink = ! links.createLink(getPackageAnchorName(pkg), new StringContent(utils.getPackageName(pkg))); Content summary = new ContentBuilder(); addSummaryComment(pkg, summary); table.addRow(pkgLink, summary); }
*** 512,522 **** * * @return a content tree for the package link */ protected Content getNavLinkPackage() { Content linkContent = ! getHyperLink(DocPath.parent.resolve(DocPaths.PACKAGE_SUMMARY), contents.packageLabel); Content li = HtmlTree.LI(linkContent); return li; } /** --- 513,523 ---- * * @return a content tree for the package link */ protected Content getNavLinkPackage() { Content linkContent = ! Links.createLink(DocPath.parent.resolve(DocPaths.PACKAGE_SUMMARY), contents.packageLabel); Content li = HtmlTree.LI(linkContent); return li; } /**
*** 547,557 **** * * @return a content tree for the tree link */ protected Content getNavLinkTree() { Content linkContent = utils.isEnclosingPackageIncluded(typeElement) ! ? getHyperLink(DocPath.parent.resolve(DocPaths.PACKAGE_TREE), contents.treeLabel) ! : getHyperLink(pathToRoot.resolve(DocPaths.OVERVIEW_TREE), contents.treeLabel); Content li = HtmlTree.LI(linkContent); return li; } } --- 548,558 ---- * * @return a content tree for the tree link */ protected Content getNavLinkTree() { Content linkContent = utils.isEnclosingPackageIncluded(typeElement) ! ? Links.createLink(DocPath.parent.resolve(DocPaths.PACKAGE_TREE), contents.treeLabel) ! : Links.createLink(pathToRoot.resolve(DocPaths.OVERVIEW_TREE), contents.treeLabel); Content li = HtmlTree.LI(linkContent); return li; } }
< prev index next >