SOM Kernel Reference 1-69
New Methods
Attributes:
readonly attribute somOffsets somInstanceDataOffsets
_get_somInstanceDataOffsets returns a sequence of structures, each of which indicates
an ancestor of the receiver class (or the receiver class itself) and the offset to the beginning
of the instance data introduced by the indicated class in an instance of the receiver class.
The somOffsets information can be used in conjunction with information derived from calls
to a SOM Interface Repository to completely determine the layout of SOM objects at
runtime.
C++ Example
#include <somcls.xh>
main()
{
int i;
SOMClassMgr *scm = somEnvironmentNew();
somOffsets so = _SOMClass–>_get_somInstanceDataOffsets();
for (i=0; i<so._length; i++)
printf(”In an instance of SOMClass, %s data starts at
%d\n”,
so._buffer[i]–>cls–>somGetName(),
so._buffer[i]–>offset);
}
Introduced Methods
Group: Instance Creation (Factory)
somAllocate
somDeallocate
somNew, somNewNoInit
somRenew, somRenewNoInit, somRenewNoInitNoZero, somRenewNoZero
Group: Initialization/Termination
somAddDynamicMethod
somClassReady
Group: Access
somGetInstancePartSize
somGetInstanceSize
somGetInstanceToken
somGetMemberToken
somGetMethodData
somGetMethodDescriptor
somGetMethodIndex
somGetMethodToken
somGetName
somGetNthMethodData
somGetNthMethodInfo
somGetNumMethods
Kommentare zu diesen Handbüchern