posted 6 years ago
Serializable is a "marker interface". If you implement it, then Java understands that objects of that class are meant to be serialized. Serialization works by special handling by the JVM. It's not really an elegant solution, but that's what the Java and JVM designers chose long ago when they invented Java. I think that if they'd have to invent it again, they would do it without this special "magic" interface; they'd probably invent an annotation instead of a marker interface. But annotations didn't exist in the time of Java version 1.0.
Jesper de Jong