:copyrightS
/* @(#) somc/ctm.efw 2.23.1.4 12/22/95 10:11:01 [7/30/96 14:44:52] */

/*
 *   COMPONENT_NAME: some
 *
 *   ORIGINS: 27
 *
 *
 *   25H7912, 10H9769  (C) COPYRIGHT International Business Machines Corp. 1992,1996
 *   All Rights Reserved
 *   Licensed Materials - Property of IBM
 *   US Government Users Restricted Rights - Use, duplication or
 *   disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
 */

:prologS
/*
 *  This file was generated by the SOM Compiler and Emitter Framework.
 *  Generated using template emitter:
 *      SOM Emitter <progname>: <version>
 */

:moduleS
#define SOM_Module_<moduleSourceFileStem>_Source

:classS
#ifndef SOM_Module_<lowerClassSourceFileStem>_Source
#define SOM_Module_<lowerClassSourceFileStem>_Source
#endif
#define <classCScopedName>_Class_Source
?#define <explicitMetaName>_Class_Source
?#define <metaClassForName>_Class_Source

:includeS
#include "<classSourceFileStem>.<ext>"

:methodsPrologS
:methodCommentS
?<--  methodComment>
:noSelfMethodPrototypeS

SOM_Scope <methodCReturnType>  SOMLINK <methodPrefix><methodName>(<methodNoSelfParamList, ...>)
:withSelfMethodPrototypeS

SOM_Scope <methodCReturnType>  SOMLINK <methodPrefix><methodName>(<methodCParamList, ...>)
:methodBodyS
{
    <somThisAssign>
    <methodClassName>MethodDebug("<methodClassName>","<methodPrefix><methodName>");

:parentMethodCallS
    <classCScopedName>_parent_<baseClassName>_<methodName>(<methodFullParamNameList, ...>);
:returnedParentMethodCallS
    return (<classCScopedName>_parent_<baseClassName>_<methodName>(<methodFullParamNameList, ...>));
:implicitMetaParentMethodCallS
    parent_<classprefix><methodName>(<methodFullParamNameList, ...>);
:returnedImplicitMetaParentMethodCallS
    return (parent_<classprefix><methodName>(<methodFullParamNameList, ...>));
:CreturnStatementS
    /* Return statement to be customized: */
    return;
:C++returnStatementS
    /* Return statement to be customized: */
    { <methodCReturnType> retVal;  return (retVal); }
:somInitCallOfDefaultInitS
    <methodPrefix>somDefaultInit(somSelf, (somInitCtrl *) NULL);
:somUninitCallOfsomDestructS
    <methodPrefix>somDestruct(somSelf, FALSE, (somDestructCtrl *) NULL);
:methodEpilogS
}
:methodsEpilogS

:InitializerS

?<--  initializerComment>
SOM_Scope void SOMLINK <instanceMethodPrefix><initializerName>(<initializerCParamList, ...>)
{
    <classCScopedName>Data *somThis; /* set in BeginInitializer */
    somInitCtrl globalCtrl;
    somBooleanVector myMask;
    <classCScopedName>MethodDebug("<classCScopedName>","<initializerName>");
    <classCScopedName>_BeginInitializer_<initializerName>;

:AssignmentOpS

?<--  assignmentOpComment>
SOM_Scope <classCScopedName> <star> SOMLINK <instanceMethodPrefix><assignmentOpName>(<assignmentOpCParamList, ...>)
{
    <classCScopedName>Data *somThis; /* set in BeginAssignmentOp */
    somAssignCtrl globalCtrl;
    somBooleanVector myMask;
    <classCScopedName>MethodDebug("<classCScopedName>","<assignmentOpName>");
    <classCScopedName>_BeginAssignmentOp;

:parentInitializerCallS
    <classCScopedName>_Init_<parentName>_somDefaultInit(somSelf, <ctrlName>);
:parentCopyInitializerCallS
    <classCScopedName>_Init_<parentName>_<initializerName>(somSelf, <ctrlName>, <fromName>);
:parentAssignOpCallS
    <classCScopedName>_Assign_<parentName>_<assignmentOpName>(somSelf, <ctrlName>, <fromName>);
:initializerEpilogS

    /*
     * local <className> initialization code added by programmer
     */
}

:AssignmentOpEpilogS

    /*
     * local <className> assignmentOp code added by programmer
     */

    return somSelf;
}

:CDestructorS

?<--  destructorComment>
SOM_Scope void SOMLINK <instanceMethodPrefix>somDestruct(<destructorCParamList, ...>)
{
    <classCScopedName>Data *somThis; /* set in BeginDestructor */
    somDestructCtrl globalCtrl;
    somBooleanVector myMask;
    <classCScopedName>MethodDebug("<classCScopedName>","<instanceMethodPrefix>somDestruct");
    <classCScopedName>_BeginDestructor;

    /*
     * local <className> deinitialization code added by programmer
     */

    <classCScopedName>_EndDestructor;
:CppDestructorS

?<--  destructorComment>
SOM_Scope void SOMLINK <instanceMethodPrefix>somDestruct(<destructorCParamList, ...>)
{
    <classCScopedName>Data *somThis; /* set in BeginDestructor */
    somDestructCtrl globalCtrl;
    somBooleanVector myMask;
    <classCScopedName>MethodDebug("<classCScopedName>","<instanceMethodPrefix>somDestruct");
    <classCScopedName>_BeginDestructor;

    /*
     * local <className> deinitialization code added by programmer
     */

    <classCScopedName>_EndDestructor;
:parentDeinitializerCallS
:CDestructorEpilogS
}

:CppDestructorEpilogS
}

:classinitS

/* Programmer Provided Class Initialization called by SOM kernel */
void SOMLINK <classInitPrefix><classinit>(SOMClass *cls)
{
}

:somallocateS

/* Programmer Provided instance allocation function */
/* returns an uninitialized instance so uses void * as return type */
SOM_Scope void * SOMLINK <somallocate>( SOMClass *cls, size_t sizeToAllocate )
{
   /* programmer replaces the following with memory allocation */
   return 0;
}

/* Programmer Provided instance deallocation function */
/* the argument is no longer an object, so uses void* as memory pointer */
SOM_Scope void SOMLINK <somdeallocate>( void *obj, size_t sizeToFree )
{
}

:epilogS
:externalInstanceMethodPrefixS
<externalprefix>
:internalInstanceMethodPrefixS
<functionprefix>
:classMethodPrefixS
<classprefix>

:noDataSomThisAssignS
/* <methodClassName>Data *somThis = <methodClassName>GetData(somSelf); */
:yesDataSomThisAssignS
<methodClassName>Data *somThis = <methodClassName>GetData(somSelf);

:instanceMethodClassNameS
<classCScopedName>
:classMethodClassNameS
M_<classCScopedName>

:classInitPrefixS
<instanceMethodPrefix>
