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

/*
 * 
 *  Classes defined in this interface
 * 
 */


#ifndef SOM_CMDocument_h
#define SOM_CMDocument_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 CMDocumentClassData (*resolve_CMDocumentClassData())
#define CMDocumentCClassData (*resolve_CMDocumentCClassData())

/*
 * Define the class name as an object type
 */
#ifndef CMDocument
#define CMDocument SOMObject
#endif
#include <Document.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 */
#ifndef ODDocument
    #define ODDocument SOMObject
#endif /* ODDocument */
#ifndef ODContainer
    #define ODContainer SOMObject
#endif /* ODContainer */
#ifndef ODDraft
    #define ODDraft SOMObject
#endif /* ODDraft */
#ifndef ODStorageUnit
    #define ODStorageUnit SOMObject
#endif /* ODStorageUnit */
#ifndef CMDocument
    #define CMDocument SOMObject
#endif /* CMDocument */
#ifndef CMDraft
    #define CMDraft SOMObject
#endif /* CMDraft */
#ifndef ODBentoContainer
    #define ODBentoContainer SOMObject
#endif /* ODBentoContainer */

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

#define CMDocument_MajorVersion 0
#define CMDocument_MinorVersion 0

/*
 * External name shortening if required
 */
#ifdef SOM_USE_SHORT_EXTERNAL_NAMES
#define CMDocumentNewClass c
#define CMDocumentClassData d
#define CMDocumentCClassData x
#endif /* SOM_USE_SHORT_EXTERNAL_NAMES */
/*--------------Migration------------*/
#define CMDocument_classObj CMDocumentClassData.classObject
#define _CMDocument CMDocument_classObj

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

/*
 * Declare the class data structure
 */
SOMEXTERN struct CMDocumentClassDataStructure {
	SOMClass *classObject;
	somMToken GetCMVersionList;
	somMToken GetDraftGut;
	somMToken InternalizeVersionList;
	somMToken ExternalizeVersionList;
	somMToken Reopen;
	somMToken GetVersionList;
	somMToken TestAndGetVersionList;
	somMToken ReleaseVersionList;
	somMToken GetHeap;
}  _CMDocumentClassData;
SOMEXTERN struct CMDocumentClassDataStructure * SOMLINK resolve_CMDocumentClassData(void);

/*
 * Declare the C specific class data structure
 */
SOMEXTERN struct CMDocumentCClassDataStructure {
	somMethodTabs parentMtab;
	somDToken instanceDataToken;
}  _CMDocumentCClassData;
SOMEXTERN struct CMDocumentCClassDataStructure * SOMLINK resolve_CMDocumentCClassData(void);

/*
 * New and Renew macros for CMDocument
 */
#define CMDocumentNew() \
   (_somNew(_CMDocument ? _CMDocument : CMDocumentNewClass(CMDocument_MajorVersion, CMDocument_MinorVersion)))
#define CMDocumentRenew(buf) \
   (_somRenew(_CMDocument ? _CMDocument : CMDocumentNewClass(CMDocument_MajorVersion, CMDocument_MinorVersion), buf))

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

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

/*
 * Override method: IncrementRefCount
 */
#define CMDocument_IncrementRefCount(somSelf,ev) \
	ODRefCntObject_IncrementRefCount(somSelf,ev)

/*
 * Override method: Release
 */
#define CMDocument_Release(somSelf,ev) \
	ODRefCntObject_Release(somSelf,ev)

/*
 * Override method: GetContainer
 */
#define CMDocument_GetContainer(somSelf,ev) \
	ODDocument_GetContainer(somSelf,ev)

/*
 * Override method: GetID
 */
#define CMDocument_GetID(somSelf,ev) \
	ODDocument_GetID(somSelf,ev)

/*
 * Override method: GetName
 */
#define CMDocument_GetName(somSelf,ev) \
	ODDocument_GetName(somSelf,ev)

/*
 * Override method: SetName
 */
#define CMDocument_SetName(somSelf,ev,name) \
	ODDocument_SetName(somSelf,ev,name)

/*
 * Override method: CollapseDrafts
 */
#define CMDocument_CollapseDrafts(somSelf,ev,from,to) \
	ODDocument_CollapseDrafts(somSelf,ev,from,to)

/*
 * Override method: GetDraft
 */
#define CMDocument_GetDraft(somSelf,ev,perms,id,draft,posCode,release) \
	ODDocument_GetDraft(somSelf,ev,perms,id,draft,posCode,release)

/*
 * Override method: Exists
 */
#define CMDocument_Exists(somSelf,ev,id,draft,posCode) \
	ODDocument_Exists(somSelf,ev,id,draft,posCode)

/*
 * Override method: GetBaseDraft
 */
#define CMDocument_GetBaseDraft(somSelf,ev,perms) \
	ODDocument_GetBaseDraft(somSelf,ev,perms)

/*
 * Override method: CreateDraft
 */
#define CMDocument_CreateDraft(somSelf,ev,below,releaseBelow) \
	ODDocument_CreateDraft(somSelf,ev,below,releaseBelow)

/*
 * Override method: SaveToAPrevDraft
 */
#define CMDocument_SaveToAPrevDraft(somSelf,ev,from,to) \
	ODDocument_SaveToAPrevDraft(somSelf,ev,from,to)

/*
 * Override method: SetBaseDraftFromForeignDraft
 */
#define CMDocument_SetBaseDraftFromForeignDraft(somSelf,ev,draft) \
	ODDocument_SetBaseDraftFromForeignDraft(somSelf,ev,draft)

/*
 * Override method: InitDocument
 */
#define CMDocument_InitDocument(somSelf,ev,container,id) \
	ODDocument_InitDocument(somSelf,ev,container,id)

/*
 * Override method: ReleaseDraft
 */
#define CMDocument_ReleaseDraft(somSelf,ev,draft) \
	ODDocument_ReleaseDraft(somSelf,ev,draft)

/*
 * New Method: GetCMVersionList
 */
typedef CMValue   (SOMLINK * somTD_CMDocument_GetCMVersionList)(CMDocument *somSelf, Environment *ev);
#define somMD_CMDocument_GetCMVersionList "::CMDocument::GetCMVersionList"
#define CMDocument_GetCMVersionList(somSelf,ev) \
    (SOM_Resolve(somSelf, CMDocument, GetCMVersionList) \
	(somSelf,ev))
#ifndef SOMGD_GetCMVersionList
    #if (defined(_GetCMVersionList) || defined(__GetCMVersionList))
        #undef _GetCMVersionList
        #undef __GetCMVersionList
        #define SOMGD_GetCMVersionList 1
    #else
        #define _GetCMVersionList CMDocument_GetCMVersionList
    #endif /* _GetCMVersionList */
#endif /* SOMGD_GetCMVersionList */

/*
 * New Method: GetDraftGut
 */
typedef CMDraft*   (SOMLINK * somTD_CMDocument_GetDraftGut)(CMDocument *somSelf, Environment *ev,
		VersionList* versionList,
		ODDraftPermissions perms,
		ODDraftID id,
		CMDraft* draft,
		ODPositionCode posCode,
		ODBoolean release);
#define somMD_CMDocument_GetDraftGut "::CMDocument::GetDraftGut"
#define CMDocument_GetDraftGut(somSelf,ev,versionList,perms,id,draft,posCode,release) \
    (SOM_Resolve(somSelf, CMDocument, GetDraftGut) \
	(somSelf,ev,versionList,perms,id,draft,posCode,release))
#ifndef SOMGD_GetDraftGut
    #if (defined(_GetDraftGut) || defined(__GetDraftGut))
        #undef _GetDraftGut
        #undef __GetDraftGut
        #define SOMGD_GetDraftGut 1
    #else
        #define _GetDraftGut CMDocument_GetDraftGut
    #endif /* _GetDraftGut */
#endif /* SOMGD_GetDraftGut */

/*
 * New Method: InternalizeVersionList
 */
typedef void   (SOMLINK * somTD_CMDocument_InternalizeVersionList)(CMDocument *somSelf, Environment *ev);
#define somMD_CMDocument_InternalizeVersionList "::CMDocument::InternalizeVersionList"
#define CMDocument_InternalizeVersionList(somSelf,ev) \
    (SOM_Resolve(somSelf, CMDocument, InternalizeVersionList) \
	(somSelf,ev))
#ifndef SOMGD_InternalizeVersionList
    #if (defined(_InternalizeVersionList) || defined(__InternalizeVersionList))
        #undef _InternalizeVersionList
        #undef __InternalizeVersionList
        #define SOMGD_InternalizeVersionList 1
    #else
        #define _InternalizeVersionList CMDocument_InternalizeVersionList
    #endif /* _InternalizeVersionList */
#endif /* SOMGD_InternalizeVersionList */

/*
 * New Method: ExternalizeVersionList
 */
typedef void   (SOMLINK * somTD_CMDocument_ExternalizeVersionList)(CMDocument *somSelf, Environment *ev);
#define somMD_CMDocument_ExternalizeVersionList "::CMDocument::ExternalizeVersionList"
#define CMDocument_ExternalizeVersionList(somSelf,ev) \
    (SOM_Resolve(somSelf, CMDocument, ExternalizeVersionList) \
	(somSelf,ev))
#ifndef SOMGD_ExternalizeVersionList
    #if (defined(_ExternalizeVersionList) || defined(__ExternalizeVersionList))
        #undef _ExternalizeVersionList
        #undef __ExternalizeVersionList
        #define SOMGD_ExternalizeVersionList 1
    #else
        #define _ExternalizeVersionList CMDocument_ExternalizeVersionList
    #endif /* _ExternalizeVersionList */
#endif /* SOMGD_ExternalizeVersionList */

/*
 * New Method: Reopen
 */
typedef void   (SOMLINK * somTD_CMDocument_Reopen)(CMDocument *somSelf, Environment *ev);
#define somMD_CMDocument_Reopen "::CMDocument::Reopen"
#define CMDocument_Reopen(somSelf,ev) \
    (SOM_Resolve(somSelf, CMDocument, Reopen) \
	(somSelf,ev))
#ifndef SOMGD_Reopen
    #if (defined(_Reopen) || defined(__Reopen))
        #undef _Reopen
        #undef __Reopen
        #define SOMGD_Reopen 1
    #else
        #define _Reopen CMDocument_Reopen
    #endif /* _Reopen */
#endif /* SOMGD_Reopen */

/*
 * New Method: GetVersionList
 */
typedef VersionList*   (SOMLINK * somTD_CMDocument_GetVersionList)(CMDocument *somSelf, Environment *ev);
#define somMD_CMDocument_GetVersionList "::CMDocument::GetVersionList"
#define CMDocument_GetVersionList(somSelf,ev) \
    (SOM_Resolve(somSelf, CMDocument, GetVersionList) \
	(somSelf,ev))
#ifndef SOMGD_GetVersionList
    #if (defined(_GetVersionList) || defined(__GetVersionList))
        #undef _GetVersionList
        #undef __GetVersionList
        #define SOMGD_GetVersionList 1
    #else
        #define _GetVersionList CMDocument_GetVersionList
    #endif /* _GetVersionList */
#endif /* SOMGD_GetVersionList */

/*
 * New Method: TestAndGetVersionList
 */
typedef VersionList*   (SOMLINK * somTD_CMDocument_TestAndGetVersionList)(CMDocument *somSelf, Environment *ev);
#define somMD_CMDocument_TestAndGetVersionList "::CMDocument::TestAndGetVersionList"
#define CMDocument_TestAndGetVersionList(somSelf,ev) \
    (SOM_Resolve(somSelf, CMDocument, TestAndGetVersionList) \
	(somSelf,ev))
#ifndef SOMGD_TestAndGetVersionList
    #if (defined(_TestAndGetVersionList) || defined(__TestAndGetVersionList))
        #undef _TestAndGetVersionList
        #undef __TestAndGetVersionList
        #define SOMGD_TestAndGetVersionList 1
    #else
        #define _TestAndGetVersionList CMDocument_TestAndGetVersionList
    #endif /* _TestAndGetVersionList */
#endif /* SOMGD_TestAndGetVersionList */

/*
 * New Method: ReleaseVersionList
 */
typedef void   (SOMLINK * somTD_CMDocument_ReleaseVersionList)(CMDocument *somSelf, Environment *ev);
#define somMD_CMDocument_ReleaseVersionList "::CMDocument::ReleaseVersionList"
#define CMDocument_ReleaseVersionList(somSelf,ev) \
    (SOM_Resolve(somSelf, CMDocument, ReleaseVersionList) \
	(somSelf,ev))
#ifndef SOMGD_ReleaseVersionList
    #if (defined(_ReleaseVersionList) || defined(__ReleaseVersionList))
        #undef _ReleaseVersionList
        #undef __ReleaseVersionList
        #define SOMGD_ReleaseVersionList 1
    #else
        #define _ReleaseVersionList CMDocument_ReleaseVersionList
    #endif /* _ReleaseVersionList */
#endif /* SOMGD_ReleaseVersionList */

/*
 * New Method: GetHeap
 */
typedef ODMemoryHeapID   (SOMLINK * somTD_CMDocument_GetHeap)(CMDocument *somSelf, Environment *ev);
#define somMD_CMDocument_GetHeap "::CMDocument::GetHeap"
#define CMDocument_GetHeap(somSelf,ev) \
    (SOM_Resolve(somSelf, CMDocument, GetHeap) \
	(somSelf,ev))
#ifndef SOMGD_GetHeap
    #if (defined(_GetHeap) || defined(__GetHeap))
        #undef _GetHeap
        #undef __GetHeap
        #define SOMGD_GetHeap 1
    #else
        #define _GetHeap CMDocument_GetHeap
    #endif /* _GetHeap */
#endif /* SOMGD_GetHeap */
#ifndef SOM_DONT_USE_INHERITED_MACROS
#define CMDocument_GetUserData ODDocument_GetUserData
#define CMDocument_SetUserData ODDocument_SetUserData
#define CMDocument_InitRefCntObject ODRefCntObject_InitRefCntObject
#define CMDocument_GetRefCount ODRefCntObject_GetRefCount
#define CMDocument_InitObject ODObject_InitObject
#define CMDocument_IsInitialized ODObject_IsInitialized
#define CMDocument_HasExtension ODObject_HasExtension
#define CMDocument_GetExtension ODObject_GetExtension
#define CMDocument_ReleaseExtension ODObject_ReleaseExtension
#define CMDocument_Purge ODObject_Purge
#define CMDocument_IsEqualTo ODObject_IsEqualTo
#define CMDocument_SubClassResponsibility ODObject_SubClassResponsibility
#define CMDocument_somDefaultInit SOMObject_somDefaultInit
#define CMDocument_somDestruct SOMObject_somDestruct
#define CMDocument_somDefaultCopyInit SOMObject_somDefaultCopyInit
#define CMDocument_somDefaultAssign SOMObject_somDefaultAssign
#define CMDocument_somDefaultConstCopyInit SOMObject_somDefaultConstCopyInit
#define CMDocument_somDefaultVCopyInit SOMObject_somDefaultVCopyInit
#define CMDocument_somDefaultConstVCopyInit SOMObject_somDefaultConstVCopyInit
#define CMDocument_somDefaultConstAssign SOMObject_somDefaultConstAssign
#define CMDocument_somDefaultVAssign SOMObject_somDefaultVAssign
#define CMDocument_somDefaultConstVAssign SOMObject_somDefaultConstVAssign
#define CMDocument_somFree SOMObject_somFree
#define CMDocument_somGetClass SOMObject_somGetClass
#define CMDocument_somGetClassName SOMObject_somGetClassName
#define CMDocument_somGetSize SOMObject_somGetSize
#define CMDocument_somIsA SOMObject_somIsA
#define CMDocument_somIsInstanceOf SOMObject_somIsInstanceOf
#define CMDocument_somRespondsTo SOMObject_somRespondsTo
#define CMDocument_somDispatch SOMObject_somDispatch
#define CMDocument_somClassDispatch SOMObject_somClassDispatch
#define CMDocument_somCastObj SOMObject_somCastObj
#define CMDocument_somResetObj SOMObject_somResetObj
#define CMDocument_somDispatchV SOMObject_somDispatchV
#define CMDocument_somDispatchL SOMObject_somDispatchL
#define CMDocument_somDispatchA SOMObject_somDispatchA
#define CMDocument_somDispatchD SOMObject_somDispatchD
#define CMDocument_somPrintSelf SOMObject_somPrintSelf
#define CMDocument_somDumpSelf SOMObject_somDumpSelf
#define CMDocument_somDumpSelfInt SOMObject_somDumpSelfInt
#endif /* SOM_DONT_USE_INHERITED_MACROS */

#endif       /* SOM_CMDocument_h */
