src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/SerializedFormBuilder.java
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/SerializedFormBuilder.java Wed Nov 27 12:18:40 2019 +0100
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/SerializedFormBuilder.java Wed Nov 27 13:08:16 2019 +0100
@@ -96,12 +96,6 @@
protected Element currentMember;
/**
- * The content that will be added to the serialized form documentation tree.
- */
- private Content contentTree;
-
-
- /**
* Construct a new SerializedFormBuilder.
* @param context the build context.
*/
@@ -137,32 +131,30 @@
//Doclet does not support this output.
return;
}
- buildSerializedForm(contentTree);
+ buildSerializedForm();
}
/**
* Build the serialized form.
*
- * @param serializedTree content tree to which the documentation will be added
* @throws DocletException if there is a problem while building the documentation
*/
- protected void buildSerializedForm(Content serializedTree) throws DocletException {
- serializedTree = writer.getHeader(resources.getText(
+ protected void buildSerializedForm() throws DocletException {
+ Content contentTree = writer.getHeader(resources.getText(
"doclet.Serialized_Form"));
- buildSerializedFormSummaries(serializedTree);
+ buildSerializedFormSummaries();
- writer.addFooter(serializedTree);
- writer.printDocument(serializedTree);
+ writer.addFooter();
+ writer.printDocument(contentTree);
}
/**
* Build the serialized form summaries.
*
- * @param serializedTree content tree to which the documentation will be added
* @throws DocletException if there is a problem while building the documentation
*/
- protected void buildSerializedFormSummaries(Content serializedTree)
+ protected void buildSerializedFormSummaries()
throws DocletException {
Content serializedSummariesTree = writer.getSerializedSummariesHeader();
for (PackageElement pkg : configuration.packages) {
@@ -170,8 +162,7 @@
buildPackageSerializedForm(serializedSummariesTree);
}
- serializedTree.add(writer.getSerializedContent(
- serializedSummariesTree));
+ writer.addSerializedContent(serializedSummariesTree);
}
/**