home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 10 Tools
/
10-Tools.zip
/
som30tk.zip
/
som30os2.zip
/
include
/
somobj.sc
< prev
next >
Wrap
Text File
|
1996-12-24
|
8KB
|
214 lines
/*
* This file was generated by the SOM Compiler.
* FileName: d:\u\otp\include\somobj.sc.
* Generated using:
* SOM Precompiler somipc: 2.29.1.19
* SOM Emitter emitsc: 2.49
*/
/*
* 96F8647, 96F8648, 96F8850 (C) Copyright IBM Corp. 1992, 1994
* All Rights Reserved
* Licensed Materials - Property of IBM
* SOMObject: System Object Model root class
*/
class: SOMObject,
functionprefix = somo_, externalstem = somob,
majorversion = 1, minorversion = 7,
filestem = somobj;
-- This is the SOM root class, all SOM classes must be descended from
-- <SOMObject>. <SOMObject> has no instance data so there is no
-- per-instance cost to to being descended from it.
-- a sequence of SOM Objects
release order:
somInit, somUninit,
somFree, somDefaultVCopyInit,
somGetClassName, somGetClass,
somIsA, somRespondsTo,
somIsInstanceOf, somGetSize,
somDumpSelf, somDumpSelfInt,
somPrintSelf, somDefaultConstVCopyInit,
somoPrivate1, somoPrivate2,
somoPrivate3, somoPrivate4,
somDispatch, somClassDispatch,
somCastObj, somResetObj,
somDefaultInit, somDestruct,
somoPrivate5, somoPrivate6,
somDefaultCopyInit, somDefaultConstCopyInit,
somDefaultAssign, somDefaultConstAssign,
somDefaultVAssign, somDefaultConstVAssign,
somoPrivate7, somoPrivate8,
somoPrivate9, somoPrivate10,
somoPrivate11, somoPrivate12,
somoPrivate13, somoPrivate14;
methods:
void somDefaultInit(som3InitCtrl* ctrl), descriptor = ::SOMObject::somDefaultInit, init;
-- A default initializer for a SOM object. Passing a null ctrl
-- indicates to the receiver that its class is the class of the
-- object being initialized, whereby the initializer will determine
-- an appropriate control structure.
void somDestruct(octet doFree,
som3DestructCtrl* ctrl), descriptor = ::SOMObject::somDestruct;
-- The default destructor for a SOM object. A nonzero <doFree>
-- indicates that the object storage should be freed by the
-- object's class (via somDeallocate) after uninitialization.
-- As with somDefaultInit, a null ctrl can be passed.
void somDefaultCopyInit(som3InitCtrl* ctrl,
SOMObject* fromObj), descriptor = ::SOMObject::somDefaultCopyInit, init;
-- A default copy constructor. Use this to make copies of objects for
-- calling methods with "by-value" argument semantics.
SOMObject* somDefaultAssign(som3AssignCtrl* ctrl,
SOMObject* fromObj), descriptor = ::SOMObject::somDefaultAssign;
-- A default assignment operator. Use this to "assign" the state of one
-- object to another.
void somDefaultConstCopyInit(som3InitCtrl* ctrl,
SOMObject* fromObj), descriptor = ::SOMObject::somDefaultConstCopyInit, init;
-- A default copy constructor that uses a const fromObj.
void somDefaultVCopyInit(som3InitCtrl* ctrl,
SOMObject* fromObj), descriptor = ::SOMObject::somDefaultVCopyInit, init;
-- A default copy constructor that uses a volatile fromObj.
void somDefaultConstVCopyInit(som3InitCtrl* ctrl,
SOMObject* fromObj), descriptor = ::SOMObject::somDefaultConstVCopyInit, init;
-- A default copy constructor that uses a const volatile fromObj.
SOMObject* somDefaultConstAssign(som3AssignCtrl* ctrl,
SOMObject* fromObj), descriptor = ::SOMObject::somDefaultConstAssign;
-- A default assignment operator that uses a const fromObj.
SOMObject* somDefaultVAssign(som3AssignCtrl* ctrl,
SOMObject* fromObj), descriptor = ::SOMObject::somDefaultVAssign;
-- A default assignment operator that uses a volatile fromObj.
SOMObject* somDefaultConstVAssign(som3AssignCtrl* ctrl,
SOMObject* fromObj), descriptor = ::SOMObject::somDefaultConstVAssign;
-- A default assignment operator that uses a const volatile fromObj.
void somInit(), descriptor = ::SOMObject::somInit;
-- Obsolete but still supported. Override somDefaultInit instead of somInit.
void somUninit(), descriptor = ::SOMObject::somUninit;
-- Obsolete but still supported. Override somDestruct instead of somUninit.
void somFree(), descriptor = ::SOMObject::somFree;
-- The default implementation just calls somDestruct.
SOMClass* somGetClass(), descriptor = ::SOMObject::somGetClass;
-- Return the receiver's class.
string somGetClassName(), descriptor = ::SOMObject::somGetClassName, dual_owned_result;
-- Return the name of the receiver's class.
long somGetSize(), descriptor = ::SOMObject::somGetSize;
-- Return the size of the receiver.
boolean somIsA(SOMClass* aClassObj), descriptor = ::SOMObject::somIsA;
-- Returns 1 (true) if the receiver responds to methods
-- introduced by <aClassObj>, and 0 (false) otherwise.
boolean somIsInstanceOf(SOMClass* aClassObj), descriptor = ::SOMObject::somIsInstanceOf;
-- Returns 1 (true) if the receiver is an instance of
-- <aClassObj> and 0 (false) otherwise.
boolean somRespondsTo(somId mId), descriptor = ::SOMObject::somRespondsTo;
-- Returns 1 (true) if the indicated method can be invoked
-- on the receiver and 0 (false) otherwise.
boolean somDispatch(somToken* retValue,
somId methodId,
...), descriptor = ::SOMObject::somDispatch;
-- This method provides a generic, class-specific dispatch mechanism.
-- It accepts as input <retValue> a pointer to the memory area to be
-- loaded with the result of dispatching the method indicated by
-- <methodId> using the arguments in <ap>. <ap> contains the object
-- on which the method is to be invoked as the first argument.
--
-- Default redispatch stubs invoke this method.
boolean somClassDispatch(SOMClass* clsObj,
somToken* retValue,
somId methodId,
...), descriptor = ::SOMObject::somClassDispatch;
-- Like somDispatch, but method resolution for static methods is done
-- according to the clsObj instance method table.
boolean somCastObj(SOMClass* castedCls), descriptor = ::SOMObject::somCastObj;
-- Changes the behavior of the target object to that implemented
-- by castedCls. This is possible when all concrete data in castedCls
-- is also concrete in the true class of the target object.
-- Returns true (1) on success, and false (0) otherwise.
boolean somResetObj(), descriptor = ::SOMObject::somResetObj;
-- reset an object to its true class. Returns true always.
SOMObject* somPrintSelf(), descriptor = ::SOMObject::somPrintSelf;
-- Uses <SOMOutCharRoutine> to write a brief string with identifying
-- information about this object. The default implementation just gives
-- the object's class name and its address in memory.
-- <self> is returned.
void somDumpSelf(long level), descriptor = ::SOMObject::somDumpSelf;
-- Uses <SOMOutCharRoutine> to write a detailed description of this object
-- and its current state.
--
-- <level> indicates the nesting level for describing compound objects
-- it must be greater than or equal to zero. All lines in the
-- description will be preceeded by <2*level> spaces.
--
-- This routine only actually writes the data that concerns the object
-- as a whole, such as class, and uses <somDumpSelfInt> to describe
-- the object's current state. This approach allows readable
-- descriptions of compound objects to be constructed.
--
-- Generally it is not necessary to override this method, if it is
-- overriden it generally must be completely replaced.
void somDumpSelfInt(long level), descriptor = ::SOMObject::somDumpSelfInt;
-- Uses <SOMOutCharRoutine> to write in the current state of this object.
-- Generally this method will need to be overridden. When overriding
-- it, begin by calling the parent class form of this method and then
-- write in a description of your class's instance data. This will
-- result in a description of all the object's instance data going
-- from its root ancestor class to its specific class.
#include <somcls.sc>