Serialization between gcj- and javac compiled classes?

Martin Egholm Nielsen martin@egholm-nielsen.dk
Thu May 27 09:52:00 GMT 2004


>>> Is there compatibility between serialized objects comming from a 
>>> Sun's javac generated class-file and a native class from gcj?
>>> (and I will have serialVersionUID defined...)
>> Yes, they should be compatible, but only if you have serialVersionUID 
>> defined.
> I don't know how libgcj calculates the serialVersionUID, but my reading 
> of the serialization specification is that if the identical class exists 
> in two different runtimes (Sun's and libgcj for example) that the 
> serialized form is compatible even without the explicit serialVersionUID.
> If libgcj does not work this way, then I would say that it is broken and 
> should be fixed.
Great - thanks!
Regards,
 Martin


More information about the Java mailing list

AltStyle によって変換されたページ (->オリジナル) /