What is meant by proper declaration of read resolve method in the
Effective Java book?
From the Serialization chapter of Effective Java:
If the class of an object being deserialized defines a readResolve method
with the proper declaration, this method is invoked on the newly created
object after it is deserialized.
What is meant by proper declaration here? Will the class even compile if
the declaration is not proper? I am finding the sentence a little bit
confusing.
No comments:
Post a Comment