
/*
 * This file was generated by the SOM Compiler.
 * FileName: \odwin\h\EXTENSN.h.
 * Generated using:
 *     SOM Precompiler somipc: 2.29.1.3
 *     SOM Emitter emith.dll: 2.41
 */

/*
 * 
 *  Theory of Operation
 * 
 * 
 *   This file defines class ODObject.  This class is the common base class
 *   for all OpenDoc classes.  It provides for extensibility through the
 *   Extensions protocol.
 * 
 *  Classes defined in this interface
 * 
 */


#ifndef SOM_ODExtension_h
#define SOM_ODExtension_h


#include <som.h>

/*
 * -- This emitter treats Method Tokens as Thunks by default.
 * -- Use the sc modifier "nothunks" to change this default
 */
#undef somresolve_
#define somresolve_(obj,mToken) ((somMethodProc*)((void)obj, mToken))



/*
 * Define class data structures as resolution macros
 */
#define ODExtensionClassData (*resolve_ODExtensionClassData())
#define ODExtensionCClassData (*resolve_ODExtensionCClassData())

/*
 * Define the class name as an object type
 */
#ifndef ODExtension
#define ODExtension SOMObject
#endif
#include <RefCtObj.h>

/*
 * Start of user-defined types:
 */
#ifndef SOMClass
    #define SOMClass SOMObject
#endif /* SOMClass */
#ifndef ODObject
    #define ODObject SOMObject
#endif /* ODObject */
#ifndef ODExtension
    #define ODExtension SOMObject
#endif /* ODExtension */
#ifndef ODRefCntObject
    #define ODRefCntObject SOMObject
#endif /* ODRefCntObject */

/*
 * End of user-defined types.
 */

#define ODExtension_MajorVersion 0
#define ODExtension_MinorVersion 0

/*
 * External name shortening if required
 */
#ifdef SOM_USE_SHORT_EXTERNAL_NAMES
#define ODExtensionNewClass c
#define ODExtensionClassData d
#define ODExtensionCClassData x
#endif /* SOM_USE_SHORT_EXTERNAL_NAMES */
/*--------------Migration------------*/
#define ODExtension_classObj ODExtensionClassData.classObject
#define _ODExtension ODExtension_classObj

/*
 * Declare the class creation procedure
 */
SOMEXTERN SOMClass * SOMLINK ODExtensionNewClass(integer4 somntmajorVersion,
		integer4 somntminorVersion);

/*
 * Declare the class data structure
 */
SOMEXTERN struct ODExtensionClassDataStructure {
	SOMClass *classObject;
	somMToken InitExtension;
	somMToken GetBase;
	somMToken BaseRemoved;
	somMToken IsValid;
	somMToken CheckValid;
}  _ODExtensionClassData;
SOMEXTERN struct ODExtensionClassDataStructure * SOMLINK resolve_ODExtensionClassData(void);

/*
 * Declare the C specific class data structure
 */
SOMEXTERN struct ODExtensionCClassDataStructure {
	somMethodTabs parentMtab;
	somDToken instanceDataToken;
}  _ODExtensionCClassData;
SOMEXTERN struct ODExtensionCClassDataStructure * SOMLINK resolve_ODExtensionCClassData(void);

/*
 * New and Renew macros for ODExtension
 */
#define ODExtensionNew() \
   (_somNew(_ODExtension ? _ODExtension : ODExtensionNewClass(ODExtension_MajorVersion, ODExtension_MinorVersion)))
#define ODExtensionRenew(buf) \
   (_somRenew(_ODExtension ? _ODExtension : ODExtensionNewClass(ODExtension_MajorVersion, ODExtension_MinorVersion), buf))

/*
 * Override method: somInit
 */
#define ODExtension_somInit(somSelf) \
	SOMObject_somInit(somSelf)

/*
 * Override method: somUninit
 */
#define ODExtension_somUninit(somSelf) \
	SOMObject_somUninit(somSelf)

/*
 * New Method: InitExtension
 */
typedef void   (SOMLINK * somTD_ODExtension_InitExtension)(ODExtension *somSelf, Environment *ev,
		ODObject* base);
#define somMD_ODExtension_InitExtension "::ODExtension::InitExtension"
#define ODExtension_InitExtension(somSelf,ev,base) \
    (SOM_Resolve(somSelf, ODExtension, InitExtension) \
	(somSelf,ev,base))
#ifndef SOMGD_InitExtension
    #if (defined(_InitExtension) || defined(__InitExtension))
        #undef _InitExtension
        #undef __InitExtension
        #define SOMGD_InitExtension 1
    #else
        #define _InitExtension ODExtension_InitExtension
    #endif /* _InitExtension */
#endif /* SOMGD_InitExtension */

/*
 * New Method: GetBase
 */
typedef ODObject*   (SOMLINK * somTD_ODExtension_GetBase)(ODExtension *somSelf, Environment *ev);
#define somMD_ODExtension_GetBase "::ODExtension::GetBase"
#define ODExtension_GetBase(somSelf,ev) \
    (SOM_Resolve(somSelf, ODExtension, GetBase) \
	(somSelf,ev))
#ifndef SOMGD_GetBase
    #if (defined(_GetBase) || defined(__GetBase))
        #undef _GetBase
        #undef __GetBase
        #define SOMGD_GetBase 1
    #else
        #define _GetBase ODExtension_GetBase
    #endif /* _GetBase */
#endif /* SOMGD_GetBase */

/*
 * New Method: BaseRemoved
 */
typedef void   (SOMLINK * somTD_ODExtension_BaseRemoved)(ODExtension *somSelf, Environment *ev);
#define somMD_ODExtension_BaseRemoved "::ODExtension::BaseRemoved"
#define ODExtension_BaseRemoved(somSelf,ev) \
    (SOM_Resolve(somSelf, ODExtension, BaseRemoved) \
	(somSelf,ev))
#ifndef SOMGD_BaseRemoved
    #if (defined(_BaseRemoved) || defined(__BaseRemoved))
        #undef _BaseRemoved
        #undef __BaseRemoved
        #define SOMGD_BaseRemoved 1
    #else
        #define _BaseRemoved ODExtension_BaseRemoved
    #endif /* _BaseRemoved */
#endif /* SOMGD_BaseRemoved */

/*
 * New Method: IsValid
 */
typedef ODBoolean   (SOMLINK * somTD_ODExtension_IsValid)(ODExtension *somSelf, Environment *ev);
#define somMD_ODExtension_IsValid "::ODExtension::IsValid"
#define ODExtension_IsValid(somSelf,ev) \
    (SOM_Resolve(somSelf, ODExtension, IsValid) \
	(somSelf,ev))
#ifndef SOMGD_IsValid
    #if (defined(_IsValid) || defined(__IsValid))
        #undef _IsValid
        #undef __IsValid
        #define SOMGD_IsValid 1
    #else
        #define _IsValid ODExtension_IsValid
    #endif /* _IsValid */
#endif /* SOMGD_IsValid */

/*
 * New Method: CheckValid
 */
typedef void   (SOMLINK * somTD_ODExtension_CheckValid)(ODExtension *somSelf, Environment *ev);
#define somMD_ODExtension_CheckValid "::ODExtension::CheckValid"
#define ODExtension_CheckValid(somSelf,ev) \
    (SOM_Resolve(somSelf, ODExtension, CheckValid) \
	(somSelf,ev))
#ifndef SOMGD_CheckValid
    #if (defined(_CheckValid) || defined(__CheckValid))
        #undef _CheckValid
        #undef __CheckValid
        #define SOMGD_CheckValid 1
    #else
        #define _CheckValid ODExtension_CheckValid
    #endif /* _CheckValid */
#endif /* SOMGD_CheckValid */
#ifndef SOM_DONT_USE_INHERITED_MACROS
#define ODExtension_InitRefCntObject ODRefCntObject_InitRefCntObject
#define ODExtension_IncrementRefCount ODRefCntObject_IncrementRefCount
#define ODExtension_Release ODRefCntObject_Release
#define ODExtension_GetRefCount ODRefCntObject_GetRefCount
#define ODExtension_InitObject ODObject_InitObject
#define ODExtension_IsInitialized ODObject_IsInitialized
#define ODExtension_HasExtension ODObject_HasExtension
#define ODExtension_GetExtension ODObject_GetExtension
#define ODExtension_ReleaseExtension ODObject_ReleaseExtension
#define ODExtension_Purge ODObject_Purge
#define ODExtension_IsEqualTo ODObject_IsEqualTo
#define ODExtension_SubClassResponsibility ODObject_SubClassResponsibility
#define ODExtension_somDefaultInit SOMObject_somDefaultInit
#define ODExtension_somDestruct SOMObject_somDestruct
#define ODExtension_somDefaultCopyInit SOMObject_somDefaultCopyInit
#define ODExtension_somDefaultAssign SOMObject_somDefaultAssign
#define ODExtension_somDefaultConstCopyInit SOMObject_somDefaultConstCopyInit
#define ODExtension_somDefaultVCopyInit SOMObject_somDefaultVCopyInit
#define ODExtension_somDefaultConstVCopyInit SOMObject_somDefaultConstVCopyInit
#define ODExtension_somDefaultConstAssign SOMObject_somDefaultConstAssign
#define ODExtension_somDefaultVAssign SOMObject_somDefaultVAssign
#define ODExtension_somDefaultConstVAssign SOMObject_somDefaultConstVAssign
#define ODExtension_somFree SOMObject_somFree
#define ODExtension_somGetClass SOMObject_somGetClass
#define ODExtension_somGetClassName SOMObject_somGetClassName
#define ODExtension_somGetSize SOMObject_somGetSize
#define ODExtension_somIsA SOMObject_somIsA
#define ODExtension_somIsInstanceOf SOMObject_somIsInstanceOf
#define ODExtension_somRespondsTo SOMObject_somRespondsTo
#define ODExtension_somDispatch SOMObject_somDispatch
#define ODExtension_somClassDispatch SOMObject_somClassDispatch
#define ODExtension_somCastObj SOMObject_somCastObj
#define ODExtension_somResetObj SOMObject_somResetObj
#define ODExtension_somDispatchV SOMObject_somDispatchV
#define ODExtension_somDispatchL SOMObject_somDispatchL
#define ODExtension_somDispatchA SOMObject_somDispatchA
#define ODExtension_somDispatchD SOMObject_somDispatchD
#define ODExtension_somPrintSelf SOMObject_somPrintSelf
#define ODExtension_somDumpSelf SOMObject_somDumpSelf
#define ODExtension_somDumpSelfInt SOMObject_somDumpSelfInt
#endif /* SOM_DONT_USE_INHERITED_MACROS */

#endif       /* SOM_ODExtension_h */
