In Serialization, whether you will use Static variables?
Answers were Sorted based on User's Feedback
Answer / chandramouli
We cannot serialize the static variables because static is
specific to the class not for the objects.
| Is This Answer Correct ? | 9 Yes | 0 No |
Answer / ranganathkini
Static variables are not serialized during object serialization.
If u want to serialize static fields, then u must use ur own
serialization overrides and implement the
java.io.Externalizable interface on the class.
| Is This Answer Correct ? | 3 Yes | 2 No |
what is meaning of JIT?
Describe what a thread-local variable is in java?
What does it mean that strings are immutable?
What is Vector?Can you elaborate how Vector is Thread safe?
Can a abstract class be defined without any abstract methods?
What is the difference between Stream Reader and Stream Writer?
What is nextint java?
Name the types of 'priority'?
why is S capital in System.out.println ????
What is the immediate superclass of the Dialog class?
what is difference between interface and abstract class..?
What is method Overriding in the perspective of OOPS?