The moose likes Java in General and the fly likes difference between Serializaton and Externalization Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Java » Java in General
Reply Bookmark "difference between Serializaton and Externalization" Watch "difference between Serializaton and Externalization" New topic
Author

difference between Serializaton and Externalization

anish jain
Ranch Hand

Joined: Feb 03, 2010
Posts: 129
In Externalization we can override readExternal() and writeExternal() to control the serialization process
In Serialization we can override readObject() and writeObject() also to control the serialization process...

I am a bit confused between these two...Could any one please let me know what's the actual difference between these two? and which one to use when?

Any help will be highly appreciated?
Carey Brown
Ranch Hand

Joined: Nov 19, 2001
Posts: 159

See: http://geekexplains.blogspot.com/2008/06/diff-between-externalizable-and.html
anish jain
Ranch Hand

Joined: Feb 03, 2010
Posts: 129
Could anybody please help me in understanding the difference between serialization and externalization with some Java code?
Steve Luke
Bartender

Joined: Jan 28, 2003
Posts: 3036
    
    4

See this thread, posted just a little while ago:
http://www.coderanch.com/t/526312/java/java/Serialization-Vs-Externalization

In that thread there is a link to a tutorial with code. It is a good place to start learning.


Steve
anish jain
Ranch Hand

Joined: Feb 03, 2010
Posts: 129
Steve Luke wrote:See this thread, posted just a little while ago:
http://www.coderanch.com/t/526312/java/java/Serialization-Vs-Externalization

In that thread there is a link to a tutorial with code. It is a good place to start learning.


As far as I could understand, it is only telling that by using Externalization we can control the process but if i am not wrong then by overriding readObject() and writeObject() in Serializable we can also achieve the same thing as with readExternal() and writeExternal() of Externalizable..


So how do they differ?

Could you please explain me with use of some Java code
anish jain
Ranch Hand

Joined: Feb 03, 2010
Posts: 129


As far as I could understand, it is only telling that by using Externalization we can control the process but if i am not wrong then by overriding readObject() and writeObject() in Serializable we can also achieve the same thing as with readExternal() and writeExternal() of Externalizable..


So how do they differ?

Could you please explain me with use of some Java code
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: difference between Serializaton and Externalization
 
Similar Threads
difference between serializationa and externalization
externalization in java
Serialization and Externalization
serialization/externalization
Serialization Vs Externalization