src/share/classes/com/sun/tools/doclets/formats/html/MethodWriterImpl.java

changeset 766
90af8d87741f
parent 554
9d9f26857129
child 798
4868a36f6fd8
equal deleted inserted replaced
758:bcbc86cc5b31 766:90af8d87741f
26 package com.sun.tools.doclets.formats.html; 26 package com.sun.tools.doclets.formats.html;
27 27
28 import java.io.*; 28 import java.io.*;
29 29
30 import com.sun.javadoc.*; 30 import com.sun.javadoc.*;
31 import com.sun.tools.doclets.formats.html.markup.*;
31 import com.sun.tools.doclets.internal.toolkit.*; 32 import com.sun.tools.doclets.internal.toolkit.*;
32 import com.sun.tools.doclets.internal.toolkit.util.*; 33 import com.sun.tools.doclets.internal.toolkit.util.*;
33 import com.sun.tools.doclets.internal.toolkit.taglets.*;
34 34
35 /** 35 /**
36 * Writes method documentation in HTML format. 36 * Writes method documentation in HTML format.
37 * 37 *
38 * @author Robert Field 38 * @author Robert Field
41 * @author Bhavesh Patel (Modified) 41 * @author Bhavesh Patel (Modified)
42 */ 42 */
43 public class MethodWriterImpl extends AbstractExecutableMemberWriter 43 public class MethodWriterImpl extends AbstractExecutableMemberWriter
44 implements MethodWriter, MemberSummaryWriter { 44 implements MethodWriter, MemberSummaryWriter {
45 45
46 private boolean printedSummaryHeader = false;
47
48 /** 46 /**
49 * Construct a new MethodWriterImpl. 47 * Construct a new MethodWriterImpl.
50 * 48 *
51 * @param writer the writer for the class that the methods belong to. 49 * @param writer the writer for the class that the methods belong to.
52 * @param classDoc the class being documented. 50 * @param classDoc the class being documented.
63 public MethodWriterImpl(SubWriterHolderWriter writer) { 61 public MethodWriterImpl(SubWriterHolderWriter writer) {
64 super(writer); 62 super(writer);
65 } 63 }
66 64
67 /** 65 /**
68 * Write the methods summary header for the given class. 66 * {@inheritDoc}
69 * 67 */
70 * @param classDoc the class the summary belongs to. 68 public Content getMemberSummaryHeader(ClassDoc classDoc,
71 */ 69 Content memberSummaryTree) {
72 public void writeMemberSummaryHeader(ClassDoc classDoc) { 70 memberSummaryTree.addContent(HtmlConstants.START_OF_METHOD_SUMMARY);
73 printedSummaryHeader = true; 71 Content memberTree = writer.getMemberTreeHeader();
74 writer.println(); 72 writer.addSummaryHeader(this, classDoc, memberTree);
75 writer.println("<!-- ========== METHOD SUMMARY =========== -->"); 73 return memberTree;
76 writer.println(); 74 }
77 writer.printSummaryHeader(this, classDoc); 75
78 } 76 /**
79 77 * {@inheritDoc}
80 /** 78 */
81 * Write the methods summary footer for the given class. 79 public Content getMethodDetailsTreeHeader(ClassDoc classDoc,
82 * 80 Content memberDetailsTree) {
83 * @param classDoc the class the summary belongs to. 81 memberDetailsTree.addContent(HtmlConstants.START_OF_METHOD_DETAILS);
84 */ 82 Content methodDetailsTree = writer.getMemberTreeHeader();
85 public void writeMemberSummaryFooter(ClassDoc classDoc) { 83 methodDetailsTree.addContent(writer.getMarkerAnchor("method_detail"));
86 writer.printSummaryFooter(this, classDoc); 84 Content heading = HtmlTree.HEADING(HtmlConstants.DETAILS_HEADING,
87 } 85 writer.methodDetailsLabel);
88 86 methodDetailsTree.addContent(heading);
89 /** 87 return methodDetailsTree;
90 * Write the inherited methods summary header for the given class. 88 }
91 * 89
92 * @param classDoc the class the summary belongs to. 90 /**
93 */ 91 * {@inheritDoc}
94 public void writeInheritedMemberSummaryHeader(ClassDoc classDoc) { 92 */
95 if(! printedSummaryHeader){ 93 public Content getMethodDocTreeHeader(MethodDoc method,
96 //We don't want inherited summary to not be under heading. 94 Content methodDetailsTree) {
97 writeMemberSummaryHeader(classDoc); 95 String erasureAnchor;
98 writeMemberSummaryFooter(classDoc); 96 if ((erasureAnchor = getErasureAnchor(method)) != null) {
99 printedSummaryHeader = true; 97 methodDetailsTree.addContent(writer.getMarkerAnchor((erasureAnchor)));
100 } 98 }
101 writer.printInheritedSummaryHeader(this, classDoc); 99 methodDetailsTree.addContent(
102 } 100 writer.getMarkerAnchor(writer.getAnchor(method)));
103 101 Content methodDocTree = writer.getMemberTreeHeader();
104 /** 102 Content heading = new HtmlTree(HtmlConstants.MEMBER_HEADING);
105 * {@inheritDoc} 103 heading.addContent(method.name());
106 */ 104 methodDocTree.addContent(heading);
107 public void writeInheritedMemberSummary(ClassDoc classDoc, 105 return methodDocTree;
108 ProgramElementDoc method, boolean isFirst, boolean isLast) { 106 }
109 writer.printInheritedSummaryMember(this, classDoc, method, isFirst); 107
110 } 108 /**
111 109 * Get the signature for the given method.
112 /**
113 * Write the inherited methods summary footer for the given class.
114 *
115 * @param classDoc the class the summary belongs to.
116 */
117 public void writeInheritedMemberSummaryFooter(ClassDoc classDoc) {
118 writer.printInheritedSummaryFooter(this, classDoc); ;
119 }
120
121 /**
122 * Write the header for the method documentation.
123 *
124 * @param classDoc the class that the methods belong to.
125 */
126 public void writeHeader(ClassDoc classDoc, String header) {
127 writer.println();
128 writer.println("<!-- ============ METHOD DETAIL ========== -->");
129 writer.println();
130 writer.anchor("method_detail");
131 writer.printTableHeadingBackground(header);
132 }
133
134 /**
135 * Write the method header for the given method.
136 * 110 *
137 * @param method the method being documented. 111 * @param method the method being documented.
138 * @param isFirst the flag to indicate whether or not the method is the 112 * @return a content object for the signature
139 * first to be documented. 113 */
140 */ 114 public Content getSignature(MethodDoc method) {
141 public void writeMethodHeader(MethodDoc method, boolean isFirst) {
142 if (! isFirst) {
143 writer.printMemberHeader();
144 }
145 writer.println();
146 String erasureAnchor;
147 if ((erasureAnchor = getErasureAnchor(method)) != null) {
148 writer.anchor(erasureAnchor);
149 }
150 writer.anchor(method);
151 writer.h3();
152 writer.print(method.name());
153 writer.h3End();
154 }
155
156 /**
157 * Write the signature for the given method.
158 *
159 * @param method the method being documented.
160 */
161 public void writeSignature(MethodDoc method) {
162 writer.displayLength = 0; 115 writer.displayLength = 0;
163 writer.pre(); 116 Content pre = new HtmlTree(HtmlTag.PRE);
164 writer.writeAnnotationInfo(method); 117 writer.addAnnotationInfo(method, pre);
165 printModifiers(method); 118 addModifiers(method, pre);
166 writeTypeParameters(method); 119 addTypeParameters(method, pre);
167 printReturnType(method); 120 addReturnType(method, pre);
168 if (configuration().linksource) { 121 if (configuration().linksource) {
169 writer.printSrcLink(method, method.name()); 122 Content methodName = new StringContent(method.name());
123 writer.addSrcLink(method, methodName, pre);
170 } else { 124 } else {
171 strong(method.name()); 125 addName(method.name(), pre);
172 } 126 }
173 writeParameters(method); 127 addParameters(method, pre);
174 writeExceptions(method); 128 addExceptions(method, pre);
175 writer.preEnd(); 129 return pre;
176 assert !writer.getMemberDetailsListPrinted(); 130 }
177 } 131
178 132 /**
179 /** 133 * {@inheritDoc}
180 * Write the deprecated output for the given method. 134 */
181 * 135 public void addDeprecated(MethodDoc method, Content methodDocTree) {
182 * @param method the method being documented. 136 addDeprecatedInfo(method, methodDocTree);
183 */ 137 }
184 public void writeDeprecated(MethodDoc method) { 138
185 printDeprecated(method); 139 /**
186 } 140 * {@inheritDoc}
187 141 */
188 /** 142 public void addComments(Type holder, MethodDoc method, Content methodDocTree) {
189 * Write the comments for the given method.
190 *
191 * @param method the method being documented.
192 */
193 public void writeComments(Type holder, MethodDoc method) {
194 ClassDoc holderClassDoc = holder.asClassDoc(); 143 ClassDoc holderClassDoc = holder.asClassDoc();
195 if (method.inlineTags().length > 0) { 144 if (method.inlineTags().length > 0) {
196 writer.printMemberDetailsListStartTag();
197 if (holder.asClassDoc().equals(classdoc) || 145 if (holder.asClassDoc().equals(classdoc) ||
198 (! (holderClassDoc.isPublic() || 146 (! (holderClassDoc.isPublic() ||
199 Util.isLinkable(holderClassDoc, configuration())))) { 147 Util.isLinkable(holderClassDoc, configuration())))) {
200 writer.dd(); 148 writer.addInlineComment(method, methodDocTree);
201 writer.printInlineComment(method);
202 writer.ddEnd();
203 } else { 149 } else {
204 String classlink = writer.codeText( 150 Content link = new RawHtml(
205 writer.getDocLink(LinkInfoImpl.CONTEXT_METHOD_DOC_COPY, 151 writer.getDocLink(LinkInfoImpl.CONTEXT_METHOD_DOC_COPY,
206 holder.asClassDoc(), method, 152 holder.asClassDoc(), method,
207 holder.asClassDoc().isIncluded() ? 153 holder.asClassDoc().isIncluded() ?
208 holder.typeName() : holder.qualifiedTypeName(), 154 holder.typeName() : holder.qualifiedTypeName(),
209 false)); 155 false));
210 writer.dd(); 156 Content codelLink = HtmlTree.CODE(link);
211 writer.strongText(holder.asClassDoc().isClass()? 157 Content strong = HtmlTree.STRONG(holder.asClassDoc().isClass()?
212 "doclet.Description_From_Class": 158 writer.descfrmClassLabel : writer.descfrmInterfaceLabel);
213 "doclet.Description_From_Interface", 159 strong.addContent(writer.getSpace());
214 classlink); 160 strong.addContent(codelLink);
215 writer.ddEnd(); 161 methodDocTree.addContent(HtmlTree.DIV(HtmlStyle.block, strong));
216 writer.dd(); 162 writer.addInlineComment(method, methodDocTree);
217 writer.printInlineComment(method);
218 writer.ddEnd();
219 } 163 }
220 } 164 }
221 } 165 }
222 166
223 /** 167 /**
224 * Write the tag output for the given method. 168 * {@inheritDoc}
225 * 169 */
226 * @param method the method being documented. 170 public void addTags(MethodDoc method, Content methodDocTree) {
227 */ 171 writer.addTagsInfo(method, methodDocTree);
228 public void writeTags(MethodDoc method) { 172 }
229 writer.printTags(method); 173
230 } 174 /**
231 175 * {@inheritDoc}
232 /** 176 */
233 * Write the method footer. 177 public Content getMethodDetails(Content methodDetailsTree) {
234 */ 178 return getMemberTree(methodDetailsTree);
235 public void writeMethodFooter() { 179 }
236 printMemberFooter(); 180
237 } 181 /**
238 182 * {@inheritDoc}
239 /** 183 */
240 * Write the footer for the method documentation. 184 public Content getMethodDoc(Content methodDocTree,
241 * 185 boolean isLastContent) {
242 * @param classDoc the class that the methods belong to. 186 return getMemberTree(methodDocTree, isLastContent);
243 */
244 public void writeFooter(ClassDoc classDoc) {
245 //No footer to write for method documentation
246 } 187 }
247 188
248 /** 189 /**
249 * Close the writer. 190 * Close the writer.
250 */ 191 */
254 195
255 public int getMemberKind() { 196 public int getMemberKind() {
256 return VisibleMemberMap.METHODS; 197 return VisibleMemberMap.METHODS;
257 } 198 }
258 199
259 public void printSummaryLabel() { 200 /**
260 writer.printText("doclet.Method_Summary"); 201 * {@inheritDoc}
261 } 202 */
262 203 public void addSummaryLabel(Content memberTree) {
263 public void printTableSummary() { 204 Content label = HtmlTree.HEADING(HtmlConstants.SUMMARY_HEADING,
264 writer.tableIndexSummary(configuration().getText("doclet.Member_Table_Summary", 205 writer.getResource("doclet.Method_Summary"));
206 memberTree.addContent(label);
207 }
208
209 /**
210 * {@inheritDoc}
211 */
212 public String getTableSummary() {
213 return configuration().getText("doclet.Member_Table_Summary",
265 configuration().getText("doclet.Method_Summary"), 214 configuration().getText("doclet.Method_Summary"),
266 configuration().getText("doclet.methods"))); 215 configuration().getText("doclet.methods"));
267 } 216 }
268 217
269 public void printSummaryTableHeader(ProgramElementDoc member) { 218 /**
219 * {@inheritDoc}
220 */
221 public String getCaption() {
222 return configuration().getText("doclet.Methods");
223 }
224
225 /**
226 * {@inheritDoc}
227 */
228 public String[] getSummaryTableHeader(ProgramElementDoc member) {
270 String[] header = new String[] { 229 String[] header = new String[] {
271 writer.getModifierTypeHeader(), 230 writer.getModifierTypeHeader(),
272 configuration().getText("doclet.0_and_1", 231 configuration().getText("doclet.0_and_1",
273 configuration().getText("doclet.Method"), 232 configuration().getText("doclet.Method"),
274 configuration().getText("doclet.Description")) 233 configuration().getText("doclet.Description"))
275 }; 234 };
276 writer.summaryTableHeader(header, "col"); 235 return header;
277 } 236 }
278 237
279 public void printSummaryAnchor(ClassDoc cd) { 238 /**
280 writer.anchor("method_summary"); 239 * {@inheritDoc}
281 } 240 */
282 241 public void addSummaryAnchor(ClassDoc cd, Content memberTree) {
283 public void printInheritedSummaryAnchor(ClassDoc cd) { 242 memberTree.addContent(writer.getMarkerAnchor("method_summary"));
284 writer.anchor("methods_inherited_from_class_" + 243 }
285 ConfigurationImpl.getInstance().getClassName(cd)); 244
286 } 245 /**
287 246 * {@inheritDoc}
288 public void printInheritedSummaryLabel(ClassDoc cd) { 247 */
289 String classlink = writer.getPreQualifiedClassLink( 248 public void addInheritedSummaryAnchor(ClassDoc cd, Content inheritedTree) {
290 LinkInfoImpl.CONTEXT_MEMBER, cd, false); 249 inheritedTree.addContent(writer.getMarkerAnchor(
291 writer.strong(); 250 "methods_inherited_from_class_" +
292 String key = cd.isClass()? 251 configuration().getClassName(cd)));
293 "doclet.Methods_Inherited_From_Class" : 252 }
294 "doclet.Methods_Inherited_From_Interface"; 253
295 writer.printText(key, classlink); 254 /**
296 writer.strongEnd(); 255 * {@inheritDoc}
297 } 256 */
298 257 public void addInheritedSummaryLabel(ClassDoc cd, Content inheritedTree) {
299 protected void printSummaryType(ProgramElementDoc member) { 258 Content classLink = new RawHtml(writer.getPreQualifiedClassLink(
259 LinkInfoImpl.CONTEXT_MEMBER, cd, false));
260 Content label = new StringContent(cd.isClass() ?
261 configuration().getText("doclet.Methods_Inherited_From_Class") :
262 configuration().getText("doclet.Methods_Inherited_From_Interface"));
263 Content labelHeading = HtmlTree.HEADING(HtmlConstants.INHERITED_SUMMARY_HEADING,
264 label);
265 labelHeading.addContent(writer.getSpace());
266 labelHeading.addContent(classLink);
267 inheritedTree.addContent(labelHeading);
268 }
269
270 /**
271 * {@inheritDoc}
272 */
273 protected void addSummaryType(ProgramElementDoc member, Content tdSummaryType) {
300 MethodDoc meth = (MethodDoc)member; 274 MethodDoc meth = (MethodDoc)member;
301 printModifierAndType(meth, meth.returnType()); 275 addModifierAndType(meth, meth.returnType(), tdSummaryType);
302 } 276 }
303 277
304 protected static void printOverridden(HtmlDocletWriter writer, 278 /**
305 Type overriddenType, MethodDoc method) { 279 * {@inheritDoc}
280 */
281 protected static void addOverridden(HtmlDocletWriter writer,
282 Type overriddenType, MethodDoc method, Content dl) {
306 if(writer.configuration.nocomment){ 283 if(writer.configuration.nocomment){
307 return; 284 return;
308 } 285 }
309 ClassDoc holderClassDoc = overriddenType.asClassDoc(); 286 ClassDoc holderClassDoc = overriddenType.asClassDoc();
310 if (! (holderClassDoc.isPublic() || 287 if (! (holderClassDoc.isPublic() ||
315 if (overriddenType.asClassDoc().isIncluded() && ! method.isIncluded()) { 292 if (overriddenType.asClassDoc().isIncluded() && ! method.isIncluded()) {
316 //The class is included but the method is not. That means that it 293 //The class is included but the method is not. That means that it
317 //is not visible so don't document this. 294 //is not visible so don't document this.
318 return; 295 return;
319 } 296 }
320 String label = "doclet.Overrides"; 297 Content label = writer.overridesLabel;
321 int context = LinkInfoImpl.CONTEXT_METHOD_OVERRIDES; 298 int context = LinkInfoImpl.CONTEXT_METHOD_OVERRIDES;
322 299
323 if (method != null) { 300 if (method != null) {
324 if(overriddenType.asClassDoc().isAbstract() && method.isAbstract()){ 301 if(overriddenType.asClassDoc().isAbstract() && method.isAbstract()){
325 //Abstract method is implemented from abstract class, 302 //Abstract method is implemented from abstract class,
326 //not overridden 303 //not overridden
327 label = "doclet.Specified_By"; 304 label = writer.specifiedByLabel;
328 context = LinkInfoImpl.CONTEXT_METHOD_SPECIFIED_BY; 305 context = LinkInfoImpl.CONTEXT_METHOD_SPECIFIED_BY;
329 } 306 }
330 String overriddenTypeLink = writer.codeText( 307 Content dt = HtmlTree.DT(HtmlTree.STRONG(label));
331 writer.getLink(new LinkInfoImpl(context, overriddenType))); 308 dl.addContent(dt);
309 Content overriddenTypeLink = new RawHtml(
310 writer.getLink(new LinkInfoImpl(context, overriddenType)));
311 Content codeOverridenTypeLink = HtmlTree.CODE(overriddenTypeLink);
332 String name = method.name(); 312 String name = method.name();
333 writer.dt(); 313 Content methlink = new RawHtml(writer.getLink(
334 writer.strongText(label);
335 writer.dtEnd();
336 writer.dd();
337 String methLink = writer.codeText(
338 writer.getLink(
339 new LinkInfoImpl(LinkInfoImpl.CONTEXT_MEMBER, 314 new LinkInfoImpl(LinkInfoImpl.CONTEXT_MEMBER,
340 overriddenType.asClassDoc(), 315 overriddenType.asClassDoc(),
341 writer.getAnchor(method), name, false) 316 writer.getAnchor(method), name, false)));
342 )); 317 Content codeMethLink = HtmlTree.CODE(methlink);
343 writer.printText("doclet.in_class", methLink, overriddenTypeLink); 318 Content dd = HtmlTree.DD(codeMethLink);
344 writer.ddEnd(); 319 dd.addContent(writer.getSpace());
320 dd.addContent(writer.getResource("doclet.in_class"));
321 dd.addContent(writer.getSpace());
322 dd.addContent(codeOverridenTypeLink);
323 dl.addContent(dd);
345 } 324 }
346 } 325 }
347 326
348 /** 327 /**
349 * Parse the &lt;Code&gt; tag and return the text. 328 * Parse the &lt;Code&gt; tag and return the text.
361 } else { 340 } else {
362 return tag.substring(begin + 6, end); 341 return tag.substring(begin + 6, end);
363 } 342 }
364 } 343 }
365 344
366 protected static void printImplementsInfo(HtmlDocletWriter writer, 345 /**
367 MethodDoc method) { 346 * {@inheritDoc}
347 */
348 protected static void addImplementsInfo(HtmlDocletWriter writer,
349 MethodDoc method, Content dl) {
368 if(writer.configuration.nocomment){ 350 if(writer.configuration.nocomment){
369 return; 351 return;
370 } 352 }
371 ImplementedMethods implementedMethodsFinder = 353 ImplementedMethods implementedMethodsFinder =
372 new ImplementedMethods(method, writer.configuration); 354 new ImplementedMethods(method, writer.configuration);
373 MethodDoc[] implementedMethods = implementedMethodsFinder.build(); 355 MethodDoc[] implementedMethods = implementedMethodsFinder.build();
374 for (int i = 0; i < implementedMethods.length; i++) { 356 for (int i = 0; i < implementedMethods.length; i++) {
375 MethodDoc implementedMeth = implementedMethods[i]; 357 MethodDoc implementedMeth = implementedMethods[i];
376 Type intfac = implementedMethodsFinder.getMethodHolder(implementedMeth); 358 Type intfac = implementedMethodsFinder.getMethodHolder(implementedMeth);
377 String methlink = ""; 359 Content intfaclink = new RawHtml(writer.getLink(new LinkInfoImpl(
378 String intfaclink = writer.codeText(
379 writer.getLink(new LinkInfoImpl(
380 LinkInfoImpl.CONTEXT_METHOD_SPECIFIED_BY, intfac))); 360 LinkInfoImpl.CONTEXT_METHOD_SPECIFIED_BY, intfac)));
381 writer.dt(); 361 Content codeIntfacLink = HtmlTree.CODE(intfaclink);
382 writer.strongText("doclet.Specified_By"); 362 Content dt = HtmlTree.DT(HtmlTree.STRONG(writer.specifiedByLabel));
383 writer.dtEnd(); 363 dl.addContent(dt);
384 writer.dd(); 364 Content methlink = new RawHtml(writer.getDocLink(
385 methlink = writer.codeText(writer.getDocLink( 365 LinkInfoImpl.CONTEXT_MEMBER, implementedMeth,
386 LinkInfoImpl.CONTEXT_MEMBER, implementedMeth, 366 implementedMeth.name(), false));
387 implementedMeth.name(), false)); 367 Content codeMethLink = HtmlTree.CODE(methlink);
388 writer.printText("doclet.in_interface", methlink, intfaclink); 368 Content dd = HtmlTree.DD(codeMethLink);
389 writer.ddEnd(); 369 dd.addContent(writer.getSpace());
390 } 370 dd.addContent(writer.getResource("doclet.in_interface"));
391 371 dd.addContent(writer.getSpace());
392 } 372 dd.addContent(codeIntfacLink);
393 373 dl.addContent(dd);
394 protected void printReturnType(MethodDoc method) { 374 }
375 }
376
377 /**
378 * Add the return type.
379 *
380 * @param method the method being documented.
381 * @param htmltree the content tree to which the return type will be added
382 */
383 protected void addReturnType(MethodDoc method, Content htmltree) {
395 Type type = method.returnType(); 384 Type type = method.returnType();
396 if (type != null) { 385 if (type != null) {
397 writer.printLink(new LinkInfoImpl(LinkInfoImpl.CONTEXT_RETURN_TYPE, 386 Content linkContent = new RawHtml(writer.getLink(
398 type)); 387 new LinkInfoImpl(LinkInfoImpl.CONTEXT_RETURN_TYPE, type)));
399 print(' '); 388 htmltree.addContent(linkContent);
400 } 389 htmltree.addContent(writer.getSpace());
401 } 390 }
402 391 }
403 protected void printNavSummaryLink(ClassDoc cd, boolean link) { 392
393 /**
394 * {@inheritDoc}
395 */
396 protected Content getNavSummaryLink(ClassDoc cd, boolean link) {
404 if (link) { 397 if (link) {
405 writer.printHyperLink("", (cd == null)? 398 return writer.getHyperLink("", (cd == null)?
406 "method_summary": 399 "method_summary":
407 "methods_inherited_from_class_" + 400 "methods_inherited_from_class_" +
408 ConfigurationImpl.getInstance().getClassName(cd), 401 configuration().getClassName(cd),
409 ConfigurationImpl.getInstance().getText("doclet.navMethod")); 402 writer.getResource("doclet.navMethod"));
410 } else { 403 } else {
411 writer.printText("doclet.navMethod"); 404 return writer.getResource("doclet.navMethod");
412 } 405 }
413 } 406 }
414 407
415 protected void printNavDetailLink(boolean link) { 408 /**
409 * {@inheritDoc}
410 */
411 protected void addNavDetailLink(boolean link, Content liNav) {
416 if (link) { 412 if (link) {
417 writer.printHyperLink("", "method_detail", 413 liNav.addContent(writer.getHyperLink("", "method_detail",
418 ConfigurationImpl.getInstance().getText("doclet.navMethod")); 414 writer.getResource("doclet.navMethod")));
419 } else { 415 } else {
420 writer.printText("doclet.navMethod"); 416 liNav.addContent(writer.getResource("doclet.navMethod"));
421 } 417 }
422 } 418 }
423 } 419 }

mercurial