From eb5d8c2f8bc30c29c743cef1166a5fce09bbbe0c Mon Sep 17 00:00:00 2001 From: Roger Riggs Date: Fri, 8 Nov 2013 17:50:24 -0500 Subject: [PATCH] 8028041: Serialized Form description of j.l.String is not consistent with the implementation Replaced incorrect description with reference to the serialization specification Reviewed-by: alanb, smarks --- jdk/src/share/classes/java/lang/String.java | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/jdk/src/share/classes/java/lang/String.java b/jdk/src/share/classes/java/lang/String.java index 9223c0ab54f..a7bed2280ca 100644 --- a/jdk/src/share/classes/java/lang/String.java +++ b/jdk/src/share/classes/java/lang/String.java @@ -122,14 +122,9 @@ public final class String /** * Class String is special cased within the Serialization Stream Protocol. * - * A String instance is written initially into an ObjectOutputStream in the - * following format: - *
-     *      {@code TC_STRING} (utf String)
-     * 
- * The String is written by method {@code DataOutput.writeUTF}. - * A new handle is generated to refer to all future references to the - * string instance within the stream. + * A String instance is written into an ObjectOutputStream according to + * + * Object Serialization Specification, Section 6.2, "Stream Elements" */ private static final ObjectStreamField[] serialPersistentFields = new ObjectStreamField[0];