why static variables cannot be serialized in java

Solutions on MaxInterview for why static variables cannot be serialized in java by the best coders in the world

showing results for - "why static variables cannot be serialized in java"
Sophia
22 Jun 2018
1Static Variable. Static variables belong to a class and not to any individual instance. The concept of serialization is concerned with the object's current state. Only data associated with a specific instance of a class is serialized, therefore static member fields are ignored during serialization.Dec 29, 2013
2