ftp.nice.ch/pub/next/developer/objc/EOF/OTC_EOFBetaExamples.1.0.bs.tar.gz#/OTC_EOFBetaExamples_V1.0/NSFoundation/ClassCluster/README.rtf

This is README.rtf in view mode; [Download] [Up]

ClassCluster.app
SHL Object Technology Center
e-mail: otccore@bou.shl.com



Overview

This application is interesting more in implementation than the app itself.  It is meant to demonstrate the two different ways to subclass from a class cluster.  Since there is no memory associated with the abstract root class, either way requires defining and allocating your own memory.  The two approaches are to use an instance of the class cluster as your memory (called a composite object in NEXTSTEP Documentation) and forwarding cluster messages to that object; or defining your own memory scheme entirely (called True Subclassing in NEXTSTEP documentation).

The class that is created for this example in both of these ways is a true computer science style array.  When an object is added at index n, it remains there even if there are empty spaces previous to n in the array (this is sometimes called a sparse array).  Both examples need only implement the initializers and the "class primitives" to obtain full class functionality.

NEXTSTEP 3.2  EOF Beta
	


Program Organization

Important Files

RealMutableArray.[hm] creates the real array subclass by using a composite NSMutableArray.  It requires inserting a NULL object anywhere there's an "empty" space.  This NULL object is never seen by the user, if the space is empty, nil is returned.

BetterRealMutableArray.[hm] creates the real array subclass by defining it's own structure as the memory for the array.

 	

Revision History 

June 94	Version 1.0.

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