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 |
What is boolean strategy?
Is java programming easy?
Explain the scope of a variable.
Why string is immutable or final in java
Is binary a low level language?
What do you mean by buffering?
Why main method is called first in java?
What is unicode in java?
What are the properties of thread?
why String class is immutable.
what do you understand by synchronization? Or what is synchronization and why is it important? Or describe synchronization in respect to multithreading? Or what is synchronization? : Java thread
byte a=5; byte b=5; byte c=a+b; System.out.println(c); whats the o/p?