• Post Reply Bookmark Topic Watch Topic
  • New Topic

Serialization  RSS feed

 
manoj kumar jena
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In the process of Serialization, we are using writeObject() method of ObjectOutputStream, which contains instanceOf Serializable test. Now my question is, why sun has made it when there is nothing in that (serializable) Interface?
 
Paul Sturrock
Bartender
Posts: 10336
Eclipse IDE Hibernate Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Serializable is what is known as a "marker" interface. Its only purpose is to identify a class as serializable, its up to whatever serializes the object to decide how it is serialized.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!