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

/*
 * 
 *    COMPONENT_NAME: somi
 * 
 *    ORIGINS: 27
 * 
 * 
 *    10H9767, 10H9769  (C) COPYRIGHT International Business Machines Corp. 1992,1994
 *    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.
 * 
 *   TypeDef: CORBA Interface for typedef definitions
 *   See CORBA 7.5.8, p.137
 */


#ifndef SOM_TypeDef_h
#define SOM_TypeDef_h


/*
 * Passthru lines: File: "C.h", "before"
 */

    #include <somtcnst.h>
    #include <somir.h>
    #include <containd.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 TypeDefClassData (*resolve_TypeDefClassData())
#define TypeDefCClassData (*resolve_TypeDefCClassData())

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

/*
 * Start of user-defined types:
 */
#ifndef SOMClass
    #define SOMClass SOMObject
#endif /* SOMClass */
#ifndef Container
    #define Container SOMObject
#endif /* Container */
typedef
struct TypeDef_TypeDescription {
Identifier name;
RepositoryId id;
RepositoryId defined_in;
TypeCode type;
} TypeDef_TypeDescription;

/*
 *  The inherited describe method returns an instance of this
 *  (TypeDescription) structure in the "value" member of the
 *  Description structure defined in the Contained interface.
 */

#ifndef SOM_DONT_USE_SHORT_NAMES
#ifndef SOMTGD_TypeDescription
    #ifdef TypeDescription
        #undef TypeDescription
        #define SOMTGD_TypeDescription 1
    #else
        #define TypeDescription TypeDef_TypeDescription
    #endif /* TypeDescription */
#endif /* SOMTGD_TypeDescription */
#endif /* SOM_DONT_USE_SHORT_NAMES */

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

#define TypeDef_MajorVersion 2
#define TypeDef_MinorVersion 1

/*
 * External name shortening if required
 */
#ifdef SOM_USE_SHORT_EXTERNAL_NAMES
#define TypeDefNewClass c
#define TypeDefClassData d
#define TypeDefCClassData x
#endif /* SOM_USE_SHORT_EXTERNAL_NAMES */
/*--------------Migration------------*/
#define TypeDef_classObj TypeDefClassData.classObject
#define _TypeDef TypeDef_classObj

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

/*
 * Declare the class data structure
 */
SOMEXTERN struct TypeDefClassDataStructure {
	SOMClass *classObject;
	somMToken _get_type;
	somMToken _set_type;
}  _TypeDefClassData;
SOMEXTERN struct TypeDefClassDataStructure * SOMLINK resolve_TypeDefClassData(void);

/*
 * Declare the C specific class data structure
 */
SOMEXTERN struct TypeDefCClassDataStructure {
	somMethodTabs parentMtab;
	somDToken instanceDataToken;
}  _TypeDefCClassData;
SOMEXTERN struct TypeDefCClassDataStructure * SOMLINK resolve_TypeDefCClassData(void);

/*
 * New and Renew macros for TypeDef
 */
#define TypeDefNew() \
   (_somNew(_TypeDef ? _TypeDef : TypeDefNewClass(TypeDef_MajorVersion, TypeDef_MinorVersion)))
#define TypeDefRenew(buf) \
   (_somRenew(_TypeDef ? _TypeDef : TypeDefNewClass(TypeDef_MajorVersion, TypeDef_MinorVersion), buf))

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

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

/*
 * Override method: somDumpSelf
 */
#define TypeDef_somDumpSelf(somSelf,level) \
	SOMObject_somDumpSelf(somSelf,level)

/*
 * Override method: somDumpSelfInt
 */
#define TypeDef_somDumpSelfInt(somSelf,level) \
	SOMObject_somDumpSelfInt(somSelf,level)

/*
 * Override method: describe
 */
#define TypeDef_describe(somSelf,ev) \
	Contained_describe(somSelf,ev)

/*
 * New Method: _get_type
 */
typedef TypeCode   (SOMLINK * somTD_TypeDef__get_type)(TypeDef *somSelf, Environment *ev);
#define somMD_TypeDef__get_type "::TypeDef::type"
#define TypeDef__get_type(somSelf,ev) \
    (SOM_Resolve(somSelf, TypeDef, _get_type) \
	(somSelf,ev))
#ifndef SOMGD_get_type
    #if (defined(_get_type) || defined(__get_type))
        #undef _get_type
        #undef __get_type
        #define SOMGD_get_type 1
    #else
        #define __get_type TypeDef__get_type
    #endif /* __get_type */
#endif /* SOMGD_get_type */

/*
 * New Method: _set_type
 */
typedef void   (SOMLINK * somTD_TypeDef__set_type)(TypeDef *somSelf, Environment *ev,
		TypeCode type);
#define somMD_TypeDef__set_type "::TypeDef::type"
#define TypeDef__set_type(somSelf,ev,type) \
    (SOM_Resolve(somSelf, TypeDef, _set_type) \
	(somSelf,ev,type))
#ifndef SOMGD_set_type
    #if (defined(_set_type) || defined(__set_type))
        #undef _set_type
        #undef __set_type
        #define SOMGD_set_type 1
    #else
        #define __set_type TypeDef__set_type
    #endif /* __set_type */
#endif /* SOMGD_set_type */
#ifndef SOM_DONT_USE_INHERITED_MACROS
#define TypeDef__get_name Contained__get_name
#define TypeDef__set_name Contained__set_name
#define TypeDef__get_id Contained__get_id
#define TypeDef__set_id Contained__set_id
#define TypeDef__get_defined_in Contained__get_defined_in
#define TypeDef__set_defined_in Contained__set_defined_in
#define TypeDef__get_somModifiers Contained__get_somModifiers
#define TypeDef__set_somModifiers Contained__set_somModifiers
#define TypeDef_within Contained_within
#define TypeDef_somDefaultInit SOMObject_somDefaultInit
#define TypeDef_somDestruct SOMObject_somDestruct
#define TypeDef_somDefaultCopyInit SOMObject_somDefaultCopyInit
#define TypeDef_somDefaultAssign SOMObject_somDefaultAssign
#define TypeDef_somDefaultConstCopyInit SOMObject_somDefaultConstCopyInit
#define TypeDef_somDefaultVCopyInit SOMObject_somDefaultVCopyInit
#define TypeDef_somDefaultConstVCopyInit SOMObject_somDefaultConstVCopyInit
#define TypeDef_somDefaultConstAssign SOMObject_somDefaultConstAssign
#define TypeDef_somDefaultVAssign SOMObject_somDefaultVAssign
#define TypeDef_somDefaultConstVAssign SOMObject_somDefaultConstVAssign
#define TypeDef_somFree SOMObject_somFree
#define TypeDef_somGetClass SOMObject_somGetClass
#define TypeDef_somGetClassName SOMObject_somGetClassName
#define TypeDef_somGetSize SOMObject_somGetSize
#define TypeDef_somIsA SOMObject_somIsA
#define TypeDef_somIsInstanceOf SOMObject_somIsInstanceOf
#define TypeDef_somRespondsTo SOMObject_somRespondsTo
#define TypeDef_somDispatch SOMObject_somDispatch
#define TypeDef_somClassDispatch SOMObject_somClassDispatch
#define TypeDef_somCastObj SOMObject_somCastObj
#define TypeDef_somResetObj SOMObject_somResetObj
#define TypeDef_somDispatchV SOMObject_somDispatchV
#define TypeDef_somDispatchL SOMObject_somDispatchL
#define TypeDef_somDispatchA SOMObject_somDispatchA
#define TypeDef_somDispatchD SOMObject_somDispatchD
#define TypeDef_somPrintSelf SOMObject_somPrintSelf
#endif /* SOM_DONT_USE_INHERITED_MACROS */

#endif       /* SOM_TypeDef_h */
