Category : Alternate Operating Systems - Quarterdeck DesqView, CP/M, etc
Archive   : PCCAPP.ZIP
Filename : PO.H

 
Output of file : PO.H contained in archive : PCCAPP.ZIP
/*
* This file is part of the Choices Operating System
* Developed by: The TAPESTRY Parallel Computing Laboratory
* University of Illinois at Urbana-Champaign
* Department of Computer Science
* 1304 W. Springfield Ave.
* Urbana, IL 61801
*
* Copyright (c) 1987, 1988, 1989, 1990, 1991
* The University of Illinois Board of Trustees.
* All Rights Reserved.
* CONFIDENTIAL INFORMATION. Distribution restricted under license agreement.
*
* Author: Peter W. Madany ([email protected])
* Author: Vincent F. Russo ([email protected])
* Contributing Author: Lee Lup Yuen ([email protected])
* Project Manager and Principal Investigator: Roy Campbell ([email protected])
*
* Funded by: NSF TAPESTRY Grant No. 1-5-30035, NASA ICLASS Grant
* No. 1-5-25469 and No. NSG1471 and AT&T Metronet Grant No. 1-5-37411.
*/
/*
* ProxiableObject.h - abstract superclass for objects that need reference
* counting. Also enhances debugging features provided
* by class Object.
*/

#ifndef ProxiableObject_h
#define ProxiableObject_h
#ifdef __GNUG__
#pragma once
#pragma interface
#endif

/*
* IMPORTANT NOTICE: if any virtual functions are added to or moved around
* in Object or ProxiableObject, corresponding changes need to be made to
* class ObjectProxy and to every Processor-dependent ObjectProxyStubs.s,
* and changes may need to be made to the ObjectProxyCatchTable in
* ObjectProxy.h.
*/

#include "Object.h"
#include "REFERENCE_COUNT.h"

#include "ProxiableObjectStar.h"

// FIX should this be a Machine Configuration parameter?
static const int ProxiableObjectTableSize = 2311;

extern ClassStar ProxiableObjectClass;
proxiable class ProxiableObject : public Object {
/*
* ProxiableObject.h - abstract superclass for objects that need reference
* counting. Also enhances debugging features provided
* by class Object.
*/

friend class ObjectProxy;
/*
* This friendship is for debugging support only.
*/
friend class Class;

private:
/*
* These static variables implement tables that store objects
* and symbolic object names.
* These tables enhance debugging and help detect storage leaks.
*/
static ProxiableObject * ProxiableObjectTable[ProxiableObjectTableSize];
static char * ProxiableObjectNameTable[ProxiableObjectTableSize];
static int ProxiableObjectsStored;

/*
* Method tableIndex: return the index of this object within the
* ProxiableObjectTable. If this object is not
* in the table, return -1.
*/
int tableIndex();

protected:
/*
* An atomic counter used for reference counting,
* since garbage collectio is not supported.
*/
REFERENCE_COUNT _referenceCount;

/*
* A pointer to another proxiable object for use by an object
* who's "parent" is actually another object.
*/
ProxiableObjectStar _real;


/* Method ~ProxiableObject: destructor */
proxiable virtual ~ProxiableObject();

/* Method noRemainingReferences: invoked when this object is
no longer used by any other object. */
proxiable virtual void noRemainingReferences();
/*
* Invoked by unreference() when the reference count goes to zero.
* The default (implemented in this class) is to call the destructor
* of this object.
*/

public:
/* Method ProxiableObject: constructor */
proxiable ProxiableObject();

/* Method intialize: initilize the tables used for debugging. */
static void initialize();
/*
* This method really should be private.
*/

/* Method classOf: rteturn the Class of this object. */
proxiable virtual Class * classOf();

/* Method reference: increment the reference count object. */
proxiable virtual void reference();

/* Method unreference: decrement the reference count of this object
* and invoke noRemainingReferences if necessary. */
proxiable virtual void unreference();


/* Method objectName: return a pointer to this object's symbolic name,
* if it has one. Otherwise return 0. */
proxiable virtual char * objectName();

/* Method setName: set this object's symbolic name. */
proxiable virtual void setName( const char * str );

/* Method writeName: write the name of this object's Class and write its
* virtual address to the given OutputStream. Also
* write this object's symbolic name if it exists. */
proxiable virtual void writeName( OutputStream * );

/* Method inspect: the same as method writeName. */
proxiable virtual void inspect( OutputStream * );


/* Method asA: returns an object of the given Class based on the same
* data as this object. Return 0 if the request cannot be
* satisified.
* This method must be overloaded to be useful. */
proxiable virtual ProxiableObjectRef asA( Class *, int & status );

/* Method asA: returns an object of the named Class based on the same
* data as this object. Return 0 if the request cannot be
* satisified.
* This method must be overloaded to be useful. */
proxiable virtual ProxiableObjectRef asA( char *, int & status );

/* Method writeInfo: Write information about this object into
* buffer. Upon return, buffer will contain a null-terminated
* string of the form "classname[address](name)", where "(name)"
* is optional. classname is the real class of this object,
* address is the kernel address of this object, name is the name
* of the object previously set by setName().
*/
void writeInfo (char *buffer);
};

#endif ProxiableObject_h


  3 Responses to “Category : Alternate Operating Systems - Quarterdeck DesqView, CP/M, etc
Archive   : PCCAPP.ZIP
Filename : PO.H

  1. Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!

  2. This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.

  3. But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/