As per docs:
The serialization runtime associates with each serializable class a version number, called a serialVersionUID, which is used during deserialization to verify that the sender and receiver of a serialized object have loaded classes for that object that are compatible with respect to serialization.
If serialVersionUID is only meant to verify whether the sender and receiver of a serialized object have loaded classes for that object, then cant the class name itself be used by jvm for verification.
No comments:
Post a Comment