What is serialVersionUID and what is its need?
The serial version UID is metadata about the serializable object, it is hash code for the serializable object. It contains information about class name, field name, field type, implemented interfaces and super classes. For each modification to serializable object, we have to update serial version UID explicitly. If we do not provide any serial version UID, JVM’s default serialization mechanism generates serial version UID for the object at runtime.
During deserialization, JVM matches the serial version UID from object stream with the serializable object which will receive the stream data. If there is a mismatch in serial version UID, JVM throws InvalidClassException
| Is This Answer Correct ? | 7 Yes | 0 No |
Can you inherit a constructor java?
what is web.xml?and its use?
Why to use nested classes in java?
What is instanceof keyword?
1) Find the Merge point of two linked lists. 2) Swap two bits of integer. 3) Reverse individual words of the sentence. 4) Reverse string without using temp string.
What is the final keyword denotes?
What is hash in java?
Why does my function print none?
What is another word for methodology?
explain copyonwritearraylist and when do we use copyonwritearraylist?
Can we return null in java?
what is the difference b/w PUT and POST method to send data to the server