Invoking overridable methods from the readObject()
method can allow the overriding method to read the state of the subclass before it is fully constructed , because the base class is deserialized first, followed by the subclass. As a result, readObject()
must not call any overridable methods.
...
Wiki Markup |
---|
*SER09-EX0:* The {{readObject()}} method may invoke the overridable method {{java.io.ObjectInputStream.defaultReadObject()}} \[[SCG 2009|AA. Bibliography#SCG 09]\]. |
...
<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="bba70c7c5a51d70e-932b3e1d-48964e91-a6558049-971a84f1330c2303bc3c8cff"><ac:plain-text-body><![CDATA[ | [[API 2006 | AA. Bibliography#API 06]] |
| ]]></ac:plain-text-body></ac:structured-macro> |
<ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="223bf6466d279f60-cd28b6af-45bb4672-90519cee-8006399d76527d6cd0a9d0fd"><ac:plain-text-body><![CDATA[ | [[Bloch 2008 | AA. Bibliography#Bloch 08]] | Item 17: "Design and document for inheritance or else prohibit it" | ]]></ac:plain-text-body></ac:structured-macro> |
...