Win a copy of Succeeding with AI this week in the Artificial Intelligence and Machine Learning forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Liutauras Vilda
  • Junilu Lacar
Sheriffs:
  • Tim Cooke
  • Jeanne Boyarsky
  • Knute Snortum
Saloon Keepers:
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Carey Brown
  • Piet Souris
Bartenders:
  • salvin francis
  • fred rosenberger
  • Frits Walraven

Serialization in Java

 
Ranch Hand
Posts: 214
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,
Could anyone please help me to know real world example of where serialization is required.
Actually i'm looking for where persistent data is used in real world application, but i think need of serialization would also help me in clarifying this?

I tried to find on google but did not satify.

Please help in this.

Thanks in Advance.
 
Sheriff
Posts: 9671
42
Android Google Web Toolkit Hibernate IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There might be many uses of serialization. You can use it to transfer data from one machine to another or use it as a replacement to a DB (although there are many features in a databases which are not in serialization)...
 
Bartender
Posts: 3648
16
Mac OS X Firefox Browser Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Jay Shukla wrote:Could anyone please help me to know real world example of where serialization is required.
Actually i'm looking for where persistent data is used in real world application, but i think need of serialization would also help me in clarifying this?



Hmm There are many real examples when you need serialization. Bank account withdrawals, database modification, etc.

Persistent data? That would be what I'm been doing lately I guess. Imagine a plain file and many clients accessing this file wanting to read and modify data in it. If the read/modify is not synchronized, clients will deadlock waiting to read/modify data because clients are waiting for the lock of the object in order to continue.

Hope this helps.
 
Rancher
Posts: 43015
76
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Serialization is never "required" - there are always other ways of achieving the same purposes. Long-time persistence in particular is not something I'd use serialization for.

Note that Java has two built-in serialization mechanisms: the binary Java-only way using the Serializable interface and Object[In|Out]putStream, and the XML way using java.beans.XML[De|En]coder classes if the Java object follow JavaBean semantics.
 
Paper jam tastes about as you would expect. Try some on this tiny ad:
Try Free Java/.NET Libraries for Word Excel PowerPoint and PDF
htttp://www.e-iceblue.com/free-apis.html
    Bookmark Topic Watch Topic
  • New Topic