Are static variables serialized in Serialization process

后端 未结 9 1644
深忆病人
深忆病人 2020-12-04 12:30

I\'m stumbled upon understanding java serialization. I have read in many documents and books that static and transient variables cannot be serialized in Java. We declare a

9条回答
  •  臣服心动
    2020-12-04 12:50

    Any static variable which has been initialised at the time of declaration will be serialized.

提交回复
热议问题