byte array to Object

Hi All...

I have array of byte and I have one user defined class which is implemented as Serializable.

This array of byte I am getting from Server...

Now I want to deserialize this array of byte to User Defined object..

do any body know how to do it?

thanx in advance

/sunil

[331 byte] By [one_by_cos] at [2007-9-26 1:22:25]
# 1
just assign the serialized object from the server to ur client object...if u r not getting ..show some code of ur's i will try to give sln if i know
balajilogsan at 2007-6-29 0:59:26 > top of Java-index,Archived Forums,Java Programming...
# 2
No Actually I want to send one object from CGI script written in C++... so I am getting problem of sending direct object to the client... and hence i'm sending some set of bytes... from server which will be deserialized on client side with User Defined Java Class./sunil
one_by_cos at 2007-6-29 0:59:26 > top of Java-index,Archived Forums,Java Programming...
# 3

If C++ is creating the object then it will not be serialized, as that's a complex Java operation that C++ does not know how to do. Conversely, if you are sending the object from Java to C++ then do not serialize it as C++ will not be able to deserialize it.

Anyway, since the object is only an array of bytes, forget about serialization entirely. Just send the bytes one at a time over whatever connection you have.

DrClap at 2007-6-29 0:59:26 > top of Java-index,Archived Forums,Java Programming...