ftp.nice.ch/Attic/openStep/implementation/gnustep/sources/objcX-0.87.tgz#/objcX-0.87/foundation

GSArchiver.h
[View GSArchiver.h] 
GSArchiver.m
[View GSArchiver.m] 
GSCoder.h
[View GSCoder.h] 
GSCoder.m
[View GSCoder.m] 
Makefile.in
 
Makefile.next
 
NSObject.h
[View NSObject.h] 
NSObject.m
[View NSObject.m] 
NSString.h
[View NSString.h] 
NSString.m
[View NSString.m] 
NXArchiver.h
[View NXArchiver.h] 
NXArchiver.m
[View NXArchiver.m] 
NXCoder.h
[View NXCoder.h] 
NXCoder.m
[View NXCoder.m] 
README
 

README

   This directory contains beginings of an OpenStep compatible FoundationKit.   This work was done in parallel with other efforts.   Hopefully, we can merge these someday.   There are only two pieces of work that have been completed to some level of usablility: NSZone and archiving/unarchiving.
   
   Mark Lakata at the Lawrence Berkeley Laboratory (LBL) contributed an implementation of NSZone.   A description is in the zone.c file.   This is more than compatibility functions.   For systems that have it, valloc() is used to allocate NSZones at page boundaries.   For systems without valloc(), malloc() is used.   The Object implementation in the objc directory of this distribution uses this NSZone implementation.   The file objc2/zone.h contains macros to translate NXZone to NSZone for compatiblility with existing code.
   
   The main purpose of doing the archiving classes was to support OpenStep style archiving and unarchiving.   There are two pairs of such classes that have been tested. NXCoder and NXArchiver are classes that use NeXTSTEP archiving functions internally.   With them you can read an archive file that was written with NeXTSTEP.   GSCoder and GSArchiver are similar classes that use GNU archiving functions internally.

   To use these classes, one has to play one small trick.   Namely, one needs to implement a -read: method like...
   
- read:(NXTypedStream *)stream
{
    GSCoder	*coder;
    
// super doesn't read from stream    [super read:stream];
    coder = NXActive_Archiver;
    [self initWithCoder:coder];
    return self;
}

The reason for this is that NeXTSTEP unarchiving software will invoke this method when a new object is encounted in the typed stream.   There's no way we can change that.  'NXActive_Archiver' is a static global variable set up by the NXArchiver or GSArchiver.   Note that an implementation of -initWithCoder: doesn't need to know if the 'coder' is a NXUnarchiver or GSUnarchiver.

   The remaining classes or header files in this directory are only completed to a degree needed to support the archiving classes.
   
   Use the Makefile.next to compile thi slibrary for NeXTSTEP.   Before
it, hide directories with same name those in /usr/include to aooid getting
onflicting header files.   One can use the targets "hide" and "unhide" in the Makefile.next to do and undo this for you.

These are the contents of the former NiCE NeXT User Group NeXTSTEP/OpenStep software archive, currently hosted by Netfuture.ch.