discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSKeyedArchiver/NSKeyedUnarchiver (was Re: GModel decision)


From: Gregory John Casamento
Subject: Re: NSKeyedArchiver/NSKeyedUnarchiver (was Re: GModel decision)
Date: Mon, 19 Jan 2004 18:18:01 -0800 (PST)

Richard,

--- Richard Frith-Macdonald <richard@brainstorm.co.uk> wrote:
> 
> On 19 Jan 2004, at 13:13, Kazunobu Kuriyama wrote:
> 
> > Attached is a list of the files found in -core that contain the 
> > implementation of -initWithCoder:/-encodeWithCoder.
> >

<...Kazunobu's analysis removed...>

> > This table shows that, broadly speaking, the modification is really 
> > time-consuming but relatively straight-forward, up to 90% of all the 
> > methods in question.

As I said, not difficult, but *tedious*.

> Yep ... especially time consuming as we want to reverse engineer the 
> encoding of the apple classes .. which, as the internal structures of 
> our classes differ from Apples,  might mean we are archiving different 
> information to what the current methods do, and reconstructing the 
> information we need from that.

I believe that, while direct compatibility would be nice, it has the following
problems:

1) We would not be directly archiving the structures in our classes and would,
instead, be "reconstructing" information when unarchiving or "constructing"
Apple compatible information when archiving.

2) As with Apple's implementation, GNUstep also has some classes which are
hidden which are used inside the .gorm file/within classes which are archived. 
This means that we'll have to know about any and all hidden classes in .nibs to
be able to effectively do this.   We would also have to be able to transform
the hidden classes we're using into the appropriate ones on MOSX.

3) Only people who have MOSX would be able to modify the code which
encodes/decodes information in the archive in GNUstep.

4) We would constantly be playing catchup with Apple, if they change their
encoding.

I believe that the correct place for any kind of MOSX<->GNUstep nib/gorm level
compatibility belongs in an application or a tool which is specifically made to
transform between the two. 

There are just too many differences between the implementations of each to
justify the effort of doing it directly in GNUstep's classes.
 
> FYI I spent several hours writing updates to NSCode.[hm] for keyed 
> archiving, and have started implementation of the NSKeyedArchiver and 
> NSKeyedUnarchiver classes.  I'm away from home (working on my laptop) 
> for a few days, but expect to commit the work to CVS on wednesday or 
> thursday. 

Cool! :)   I think we need open debate on the points I've raised above.

GJC

=====
Gregory John Casamento -- CEO/President Open Logic Corp.
-- bheron on #gnustep, #linuxstep, & #gormtalk ---------------- 
Please sign the petition against software patents at: 
http://www.petitiononline.com/pasp01/petition.html 
-- Main Developer of Gorm (featured in April Linux Journal) ---

__________________________________
Do you Yahoo!?
Yahoo! Hotjobs: Enter the "Signing Bonus" Sweepstakes
http://hotjobs.sweepstakes.yahoo.com/signingbonus




reply via email to

[Prev in Thread] Current Thread [Next in Thread]