This is the mail archive of the
java-discuss@sourceware.cygnus.com
mailing list for the Java project.
Re: object serialization
- To: Warren Levy <warrenl@cygnus.com>
- Subject: Re: object serialization
- From: Jeff Sturm <jsturm@sigma6.com>
- Date: Thu, 24 Jun 1999 10:11:59 -0400
- CC: Tom Tromey <tromey@cygnus.com>, java-discuss@sourceware.cygnus.com
- Organization: AppNet Systems Inc.
- References: <Pine.SOL.3.91.990623222952.23987P-100000@fencer.cygnus.com>
Warren Levy wrote:
>
> On Mon, 21 Jun 1999, Tom Tromey wrote:
>
> > >>>>> "Jeff" == Jeff Sturm <jsturm@sigma6.com> writes:
> >
> > Jeff> Who is working on object serialization (java.io.Object* classes)
> > Jeff> for libgcj?
> >
> > I don't think anybody is working on them right now.
>
> I'm not working on them right now but I should be dealing with them in
> the coming months. Please keep in touch so we don't cover the same ground.
OK. Currently I have all stubs written (I can compile with them) and
I'm working through the thorny details of TC_CLASSDESC... unfortunately
the object serialization spec from Sun doesn't quite match the behavior
of 1.1, so I had to resort to running some tests under the JDK and doing
a little guesswork.
I underestimated the difficulty of a clean-room implementation... there
are a lot of subtleties in object serialization. For example,
Serializable objects must be created by readObject() without invoking
any constructor. (Externalizable objects on the other hand must have a
public default constructor). I haven't yet looked closely at CNI to see
if this is possible with documented calls.
I hope that by the end of this week I can read/write Externalizable
objects. Serializable will follow... I need some native code to make it
work.
--
Jeff Sturm
jsturm@sigma6.com