@Override
protected void generateOtherFiles(RootDoc rootDoc, ClassTree classTree)
throws Exception {
super.generateOtherFiles(rootDoc, classTree);
HtmlDocletWriter writer = new HtmlDocletWriter(configuration, "jsdoc.html");
writer.html();
writer.head();
writer.link("rel='stylesheet' type='text/css' href='jsdoc.css'");
writer.headEnd();
writer.body("white", true);
writer.h1("Exported JavaScript-API: Index of Classes");
writer.ul();
ClassDoc[] classes = rootDoc.classes();
Arrays.sort(classes);
for (ClassDoc clz : classes) {
if (isExportable(clz) && hasMethods(clz) && ! isExportedClosure(clz.methods()[0])) {
String className = getExportedName(clz, false);
writer.li();
writer.println("<a href=#" + className + ">" + className + "</a>");
}
}
writer.ulEnd();
for (ClassDoc clz : classes) {
if (isExportable(clz) && hasMethods(clz) && ! isExportedClosure(clz.methods()[0])) {
String className = getExportedName(clz, false);
writer.h2("<div id=" + className + ">"+ getExportedPackage(clz) + "." + className + "</div>");
writer.println("<div class=jsdocText>" + filter(clz.commentText()) + "</div>");
writer.table(1, "100%", 0, 0);
boolean firstcon = true;
for (ConstructorDoc cd : clz.constructors()) {
if (isExportable(cd)) {
if (firstcon) {
writer.tr();
writer.tdColspanBgcolorStyle(2, "", "jsdocHeader");
writer.print("Constructors");
firstcon = false;
writer.tdEnd();
writer.trEnd();
}
writer.tr();
writer.tdVAlignClass("top", "jsdocRetType");
writer.print(" ");
writer.tdEnd();
writer.tdVAlignClass("top", "jsdocMethod");
writer.print("<span class=jsdocMethodName>" + cd.name() + "</span>(");
writeParameters(writer, cd.parameters());
writer.print(")");
writer.br();
writer.print("<span class=jsdocComment>"
+ filter(cd.commentText()) + "</span>");
writer.tdEnd();
writer.trEnd();
}
}
firstcon = true;
for (MethodDoc cd : clz.methods()) {
if (isExportable(cd)) {
if (firstcon) {
writer.tr();
writer.tdColspanBgcolorStyle(2, "", "jsdocHeader");
writer.print("Methods");
firstcon = false;
writer.tdEnd();
writer.trEnd();
}
writer.tr();
writer.tdVAlignClass("top", "jsdocRetType");
writer.print(getExportedName(cd.returnType(), true));
writer.tdEnd();
writer.tdVAlignClass("top", "jsdocMethod");
writer.print(
"<b class=jsdocMethodName>" + getExportedName(cd) + "</b>"
+ "(");
writeParameters(writer, cd.parameters());
writer.print(")");
writer.br();
writer.print("<span class=jsdocComment>"
+ filter(cd.commentText()) + "</span>");
writer.tdEnd();
writer.trEnd();
}
}
writer.tableEnd();
writer.br();
writer.hr();
}
}
writer.bodyEnd();
writer.htmlEnd();
writer.flush();
writer.close();
generateGss(rootDoc, classTree);
generateGssWiki(rootDoc, classTree);
}