author | hannesw |
Wed, 27 Nov 2019 13:08:16 +0100 | |
changeset 59294 | 48b88b9c11eb |
parent 54544 | 97a4b8f46a49 |
permissions | -rw-r--r-- |
54544
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
1 |
/* |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
2 |
* Copyright (c) 2019, Oracle and/or its affiliates. All rights reserved. |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
3 |
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
4 |
* |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
5 |
* This code is free software; you can redistribute it and/or modify it |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
6 |
* under the terms of the GNU General Public License version 2 only, as |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
7 |
* published by the Free Software Foundation. Oracle designates this |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
8 |
* particular file as subject to the "Classpath" exception as provided |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
9 |
* by Oracle in the LICENSE file that accompanied this code. |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
10 |
* |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
11 |
* This code is distributed in the hope that it will be useful, but WITHOUT |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
12 |
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
13 |
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
14 |
* version 2 for more details (a copy is included in the LICENSE file that |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
15 |
* accompanied this code). |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
16 |
* |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
17 |
* You should have received a copy of the GNU General Public License version |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
18 |
* 2 along with this work; if not, write to the Free Software Foundation, |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
19 |
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
20 |
* |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
21 |
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
22 |
* or visit www.oracle.com if you need additional information or have any |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
23 |
* questions. |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
24 |
*/ |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
25 |
|
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
26 |
package jdk.javadoc.internal.doclets.formats.html; |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
27 |
|
59294
48b88b9c11eb
8223378: CSS solution for navbar problem with <a> elements is not ideal
hannesw
parents:
54544
diff
changeset
|
28 |
import jdk.javadoc.internal.doclets.formats.html.markup.BodyContents; |
48b88b9c11eb
8223378: CSS solution for navbar problem with <a> elements is not ideal
hannesw
parents:
54544
diff
changeset
|
29 |
import jdk.javadoc.internal.doclets.formats.html.markup.ContentBuilder; |
54544
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
30 |
import jdk.javadoc.internal.doclets.formats.html.markup.HtmlStyle; |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
31 |
import jdk.javadoc.internal.doclets.formats.html.markup.HtmlTag; |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
32 |
import jdk.javadoc.internal.doclets.formats.html.markup.HtmlTree; |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
33 |
import jdk.javadoc.internal.doclets.formats.html.markup.Navigation; |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
34 |
import jdk.javadoc.internal.doclets.formats.html.markup.Navigation.PageMode; |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
35 |
import jdk.javadoc.internal.doclets.formats.html.markup.RawHtml; |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
36 |
import jdk.javadoc.internal.doclets.toolkit.Content; |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
37 |
import jdk.javadoc.internal.doclets.toolkit.util.DocFileIOException; |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
38 |
import jdk.javadoc.internal.doclets.toolkit.util.DocPath; |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
39 |
|
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
40 |
/** |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
41 |
* Abstract class to generate the overview files. |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
42 |
* |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
43 |
* <p><b>This is NOT part of any supported API. |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
44 |
* If you write code that depends on this, you do so at your own risk. |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
45 |
* This code and its internal interfaces are subject to change or |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
46 |
* deletion without notice.</b> |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
47 |
* |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
48 |
*/ |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
49 |
public abstract class AbstractOverviewIndexWriter extends HtmlDocletWriter { |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
50 |
|
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
51 |
protected Navigation navBar; |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
52 |
|
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
53 |
/** |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
54 |
* Constructs the AbstractOverviewIndexWriter. |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
55 |
* |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
56 |
* @param configuration The current configuration |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
57 |
* @param filename Name of the module index file to be generated. |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
58 |
*/ |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
59 |
public AbstractOverviewIndexWriter(HtmlConfiguration configuration, |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
60 |
DocPath filename) { |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
61 |
super(configuration, filename); |
59294
48b88b9c11eb
8223378: CSS solution for navbar problem with <a> elements is not ideal
hannesw
parents:
54544
diff
changeset
|
62 |
this.navBar = new Navigation(null, configuration, PageMode.OVERVIEW, path); |
54544
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
63 |
} |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
64 |
|
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
65 |
/** |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
66 |
* Adds the top text (from the -top option), the upper |
59294
48b88b9c11eb
8223378: CSS solution for navbar problem with <a> elements is not ideal
hannesw
parents:
54544
diff
changeset
|
67 |
* navigation bar, and then the title (from the"-header" |
54544
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
68 |
* option), at the top of page. |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
69 |
* |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
70 |
* @param header the documentation tree to which the navigation bar header will be added |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
71 |
*/ |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
72 |
protected void addNavigationBarHeader(Content header) { |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
73 |
addTop(header); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
74 |
navBar.setUserHeader(getUserHeaderFooter(true)); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
75 |
header.add(navBar.getContent(true)); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
76 |
} |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
77 |
|
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
78 |
/** |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
79 |
* Adds the lower navigation bar and the bottom text |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
80 |
* (from the -bottom option) at the bottom of page. |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
81 |
* |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
82 |
* @param footer the documentation tree to which the navigation bar footer will be added |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
83 |
*/ |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
84 |
protected void addNavigationBarFooter(Content footer) { |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
85 |
navBar.setUserFooter(getUserHeaderFooter(false)); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
86 |
footer.add(navBar.getContent(false)); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
87 |
addBottom(footer); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
88 |
} |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
89 |
|
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
90 |
/** |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
91 |
* Adds the overview summary comment for this documentation. Add one line |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
92 |
* summary at the top of the page and generate a link to the description, |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
93 |
* which is added at the end of this page. |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
94 |
* |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
95 |
* @param main the documentation tree to which the overview header will be added |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
96 |
*/ |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
97 |
protected void addOverviewHeader(Content main) { |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
98 |
addConfigurationTitle(main); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
99 |
if (!utils.getFullBody(configuration.overviewElement).isEmpty()) { |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
100 |
HtmlTree div = new HtmlTree(HtmlTag.DIV); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
101 |
div.setStyle(HtmlStyle.contentContainer); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
102 |
addOverviewComment(div); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
103 |
main.add(div); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
104 |
} |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
105 |
} |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
106 |
|
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
107 |
/** |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
108 |
* Adds the overview comment as provided in the file specified by the |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
109 |
* "-overview" option on the command line. |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
110 |
* |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
111 |
* @param htmltree the documentation tree to which the overview comment will |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
112 |
* be added |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
113 |
*/ |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
114 |
protected void addOverviewComment(Content htmltree) { |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
115 |
if (!utils.getFullBody(configuration.overviewElement).isEmpty()) { |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
116 |
addInlineComment(configuration.overviewElement, htmltree); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
117 |
} |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
118 |
} |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
119 |
|
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
120 |
/** |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
121 |
* Generate and prints the contents in the index file. |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
122 |
* |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
123 |
* @param title the title of the window |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
124 |
* @param description the content for the description META tag |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
125 |
* @throws DocFileIOException if there is a problem building the package index file |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
126 |
*/ |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
127 |
protected void buildOverviewIndexFile(String title, String description) |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
128 |
throws DocFileIOException { |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
129 |
String windowOverview = resources.getText(title); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
130 |
Content body = getBody(getWindowTitle(windowOverview)); |
59294
48b88b9c11eb
8223378: CSS solution for navbar problem with <a> elements is not ideal
hannesw
parents:
54544
diff
changeset
|
131 |
Content header = new ContentBuilder(); |
54544
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
132 |
addNavigationBarHeader(header); |
59294
48b88b9c11eb
8223378: CSS solution for navbar problem with <a> elements is not ideal
hannesw
parents:
54544
diff
changeset
|
133 |
Content main = new ContentBuilder(); |
54544
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
134 |
addOverviewHeader(main); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
135 |
addIndex(main); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
136 |
Content footer = HtmlTree.FOOTER(); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
137 |
addNavigationBarFooter(footer); |
59294
48b88b9c11eb
8223378: CSS solution for navbar problem with <a> elements is not ideal
hannesw
parents:
54544
diff
changeset
|
138 |
body.add(new BodyContents() |
48b88b9c11eb
8223378: CSS solution for navbar problem with <a> elements is not ideal
hannesw
parents:
54544
diff
changeset
|
139 |
.setHeader(header) |
48b88b9c11eb
8223378: CSS solution for navbar problem with <a> elements is not ideal
hannesw
parents:
54544
diff
changeset
|
140 |
.addMainContent(main) |
48b88b9c11eb
8223378: CSS solution for navbar problem with <a> elements is not ideal
hannesw
parents:
54544
diff
changeset
|
141 |
.setFooter(footer) |
48b88b9c11eb
8223378: CSS solution for navbar problem with <a> elements is not ideal
hannesw
parents:
54544
diff
changeset
|
142 |
.toContent()); |
54544
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
143 |
printHtmlDocument( |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
144 |
configuration.metakeywords.getOverviewMetaKeywords(title, configuration.doctitle), |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
145 |
description, body); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
146 |
} |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
147 |
|
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
148 |
/** |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
149 |
* Adds the index to the documentation tree. |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
150 |
* |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
151 |
* @param main the document tree to which the packages/modules list will be added |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
152 |
*/ |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
153 |
protected abstract void addIndex(Content main); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
154 |
|
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
155 |
/** |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
156 |
* Adds the doctitle to the documentation tree, if it is specified on the command line. |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
157 |
* |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
158 |
* @param body the document tree to which the title will be added |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
159 |
*/ |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
160 |
protected void addConfigurationTitle(Content body) { |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
161 |
if (configuration.doctitle.length() > 0) { |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
162 |
Content title = new RawHtml(configuration.doctitle); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
163 |
Content heading = HtmlTree.HEADING(Headings.PAGE_TITLE_HEADING, |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
164 |
HtmlStyle.title, title); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
165 |
Content div = HtmlTree.DIV(HtmlStyle.header, heading); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
166 |
body.add(div); |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
167 |
} |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
168 |
} |
97a4b8f46a49
8222395: Refactor the abstract classes of package and module index writer
pmuthuswamy
parents:
diff
changeset
|
169 |
} |