Re: is serialization really a performance hog?
- From: EJP <esmond.not.pitt@xxxxxxxxxxxxxxx>
- Date: Mon, 21 Aug 2006 00:33:12 GMT
Daisy wrote:
To implement Externalizable, we would have to send reference objects
separately,
No you don't, you can just call out.writeObject()/in.readObject() inside the writeExternal/readExternal methods respectively and they will be completely reconstructed.
then use some unique identifer/lookup like hashcode to
re-associate the reference objects at the client.
Unnecessary, see above, serialization will do that for you.
QUESTIONS
I wouldn't serialize the simple object. I would just send its five fields directly with the methods of DataOutputStream/DataInputStream, and use serialization just for the context objects. If they're also simple I would send their pieces directly too.
3. Does inheritance complicate serialization?
Not much, it's just a recursion, not much different from handling the reachable objects actually.
.
- References:
- is serialization really a performance hog?
- From: Daisy
- is serialization really a performance hog?
- Prev by Date: Re: Drag & Drop email from outlook to Swing
- Next by Date: Re: rmi, two binding methods, what differences?
- Previous by thread: is serialization really a performance hog?
- Next by thread: Re: is serialization really a performance hog?
- Index(es):
Relevant Pages
|