What's the difference between Serialization and simply store the object on disk?
问题 I am confused about this. Since when doing implementation of Serializable class, we need to use classes like FileOutputStream , ObjectOutputStream or something like that. Then why not we just use those classes to do things like output a object to a file and input a object from a file to maintain the status of a object directly? Why should we first implement Serializable and then do the same thing? 回答1: Understand it like this... Serializable is marker interface which denotes that the object