home *** CD-ROM | disk | FTP | other *** search
/ Power GUI Programming with VisualAge C++ / powergui.iso / trialva / ibmcppw / include / sombacls.h < prev    next >
Encoding:
C/C++ Source or Header  |  1996-02-22  |  14.1 KB  |  377 lines

  1.  
  2. /*
  3.  * This file was generated by the SOM Compiler.
  4.  * FileName: h:\somnt\include\sombacls.h.
  5.  * Generated using:
  6.  *     SOM Precompiler somipc: Development
  7.  *     SOM Emitter emith.dll: Development
  8.  */
  9.  
  10. /*
  11.  * 
  12.  *    COMPONENT_NAME: somu
  13.  * 
  14.  *    ORIGINS: 27
  15.  * 
  16.  * 
  17.  *    10H9767, 10H9769  (C) COPYRIGHT International Business Machines Corp. 1992,1994
  18.  *    All Rights Reserved
  19.  *    Licensed Materials - Property of IBM
  20.  *    US Government Users Restricted Rights - Use, duplication or
  21.  *    disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
  22.  * 
  23.  */
  24.  
  25.  
  26. #ifndef SOM_SOMMBeforeAfter_h
  27. #define SOM_SOMMBeforeAfter_h
  28.  
  29.  
  30. #include <som.h>
  31.  
  32. /*
  33.  * -- This emitter treats Method Tokens as Thunks by default.
  34.  * -- Use the sc modifier "nothunks" to change this default
  35.  */
  36. #undef somresolve_
  37. #define somresolve_(obj,mToken) ((somMethodProc*)((void)obj, mToken))
  38.  
  39. /*
  40.  * Define the class name as an object type
  41.  */
  42. #ifndef SOMMBeforeAfter
  43. #define SOMMBeforeAfter SOMObject
  44. #endif
  45. #include <somcls.h>
  46.  
  47. /*
  48.  * Start of user-defined types:
  49.  */
  50. #ifndef SOMClass
  51.     #define SOMClass SOMObject
  52. #endif /* SOMClass */
  53.  
  54. /*
  55.  * End of user-defined types.
  56.  */
  57.  
  58. #define SOMMBeforeAfter_MajorVersion 2
  59. #define SOMMBeforeAfter_MinorVersion 1
  60.  
  61. /*
  62.  * External name shortening if required
  63.  */
  64. #ifdef SOM_USE_SHORT_EXTERNAL_NAMES
  65. #define SOMMBeforeAfterNewClass c
  66. #define SOMMBeforeAfterClassData d
  67. #define SOMMBeforeAfterCClassData x
  68. #endif /* SOM_USE_SHORT_EXTERNAL_NAMES */
  69. /*--------------Migration------------*/
  70. #define SOMMBeforeAfter_classObj SOMMBeforeAfterClassData.classObject
  71. #define _SOMMBeforeAfter SOMMBeforeAfter_classObj
  72.  
  73. /*
  74.  * Declare the class creation procedure
  75.  */
  76. SOMEXTERN
  77. #if (defined(SOM_Module_sombacls_Source) || defined(SOMMBeforeAfter_Class_Source) || defined (SOM_DONT_IMPORT_CLASS_SOMMBeforeAfter))
  78. WIN32_DLLEXPORT
  79. #else
  80. WIN32_DLLIMPORT
  81. #endif
  82. SOMClass * SOMLINK SOMMBeforeAfterNewClass(integer4 somntmajorVersion,
  83.         integer4 somntminorVersion);
  84.  
  85. /*
  86.  * Declare the class data structure
  87.  */
  88. SOMEXTERN struct SOMMBeforeAfterClassDataStructure {
  89.     SOMClass *classObject;
  90.     somMToken sommBeforeMethod;
  91.     somMToken sommAfterMethod;
  92. #if (defined(SOM_Module_sombacls_Source) || defined(SOMMBeforeAfter_Class_Source) || defined (SOM_DONT_IMPORT_CLASS_SOMMBeforeAfter))
  93. } WIN32_DLLEXPORT SOMDLINK SOMMBeforeAfterClassData;
  94. #else
  95. } WIN32_DLLIMPORT SOMDLINK SOMMBeforeAfterClassData;
  96. #endif
  97.  
  98. /*
  99.  * Declare the C specific class data structure
  100.  */
  101. SOMEXTERN struct SOMMBeforeAfterCClassDataStructure {
  102.     somMethodTabs parentMtab;
  103.     somDToken instanceDataToken;
  104.     somMethodProc *sommBeforeMethod;
  105.     somMethodProc *sommAfterMethod;
  106. #if (defined(SOM_Module_sombacls_Source) || defined(SOMMBeforeAfter_Class_Source) || defined (SOM_DONT_IMPORT_CLASS_SOMMBeforeAfter))
  107. } WIN32_DLLEXPORT SOMDLINK SOMMBeforeAfterCClassData;
  108. #else
  109. } WIN32_DLLIMPORT SOMDLINK SOMMBeforeAfterCClassData;
  110. #endif
  111.  
  112. /*
  113.  * New and Renew macros for SOMMBeforeAfter
  114.  */
  115. #define SOMMBeforeAfterNew() \
  116.    (_somNew(_SOMMBeforeAfter ? _SOMMBeforeAfter : SOMMBeforeAfterNewClass(SOMMBeforeAfter_MajorVersion, SOMMBeforeAfter_MinorVersion)))
  117. #define SOMMBeforeAfterRenew(buf) \
  118.    (_somRenew(_SOMMBeforeAfter ? _SOMMBeforeAfter : SOMMBeforeAfterNewClass(SOMMBeforeAfter_MajorVersion, SOMMBeforeAfter_MinorVersion), buf))
  119.  
  120. /*
  121.  * Override method: somDefaultInit
  122.  */
  123. #define SOMMBeforeAfter_somDefaultInit(somSelf,ctrl) \
  124.     SOMObject_somDefaultInit(somSelf,ctrl)
  125.  
  126. /*
  127.  * Override method: somInitMIClass
  128.  */
  129. #define SOMMBeforeAfter_somInitMIClass(somSelf,inherit_vars,className,parentClasses,dataSize,dataAlignment,maxStaticMethods,majorVersion,minorVersion) \
  130.     SOMClass_somInitMIClass(somSelf,inherit_vars,className,parentClasses,dataSize,dataAlignment,maxStaticMethods,majorVersion,minorVersion)
  131.  
  132. /*
  133.  * New Method: sommBeforeMethod
  134.  */
  135. typedef boolean   SOMLINK somTP_SOMMBeforeAfter_sommBeforeMethod(SOMMBeforeAfter *somSelf, Environment *ev,
  136.         SOMObject* object,
  137.         somId methodId,
  138.         va_list ap);
  139. typedef somTP_SOMMBeforeAfter_sommBeforeMethod *somTD_SOMMBeforeAfter_sommBeforeMethod;
  140. #define somMD_SOMMBeforeAfter_sommBeforeMethod "::SOMMBeforeAfter::sommBeforeMethod"
  141. #define SOMMBeforeAfter_sommBeforeMethod(somSelf,ev,object,methodId,ap) \
  142.     (SOM_Resolve(somSelf, SOMMBeforeAfter, sommBeforeMethod) \
  143.     (somSelf,ev,object,methodId,ap))
  144.  
  145. /*
  146.  * legacy support for non-system-linkage vararg stub
  147.  * use -mnolegacy to avoid generating this stub.
  148.  */
  149. #ifdef SOMMBeforeAfter_VA_EXTERN
  150.     SOMEXTERN
  151. #else
  152.     static
  153. #endif
  154. boolean   va_SOMMBeforeAfter_sommBeforeMethod(SOMMBeforeAfter *somSelf, Environment *ev,
  155.         SOMObject* object,
  156.         somId methodId,
  157.         ...)
  158. #if (defined(SOMMBeforeAfter_VA_STUBS)||!defined(SOMMBeforeAfter_VA_EXTERN))
  159. {
  160.     boolean result;
  161.     va_list ap;
  162.     va_start(ap, methodId);
  163.     result = SOMMBeforeAfter_sommBeforeMethod(somSelf,ev,object,methodId,ap);
  164.     va_end(ap);
  165.     return (result);
  166. }    
  167. #else
  168.     ;
  169. #endif
  170.  
  171. /*
  172.  * normal vararg stubs
  173.  */
  174. #ifndef SOMGD_va_sommBeforeMethod
  175.    #ifdef va_sommBeforeMethod
  176.       #undef va_sommBeforeMethod
  177.       #define SOMGD_va_sommBeforeMethod 1
  178.    #else
  179.       #define va_sommBeforeMethod somva_SOMMBeforeAfter_sommBeforeMethod
  180.    #endif /* va_sommBeforeMethod */
  181. #endif /* SOMGD_va_sommBeforeMethod */
  182. #ifndef SOMGD_sommBeforeMethod
  183.     #if (defined(_sommBeforeMethod) || defined(__sommBeforeMethod))
  184.         #undef _sommBeforeMethod
  185.         #undef __sommBeforeMethod
  186.         #define SOMGD_sommBeforeMethod 1
  187.     #else
  188.         #define _sommBeforeMethod somva_SOMMBeforeAfter_sommBeforeMethod
  189.     #endif /* _sommBeforeMethod */
  190. #endif /* SOMGD_sommBeforeMethod */
  191. #ifdef SOMMBeforeAfter_VA_EXTERN
  192.     SOMEXTERN
  193. #else
  194.     static
  195. #endif
  196. boolean  SOMLINK somva_SOMMBeforeAfter_sommBeforeMethod(SOMMBeforeAfter *somSelf, Environment *ev,
  197.         SOMObject* object,
  198.         somId methodId,
  199.         ...)
  200. #if (defined(SOMMBeforeAfter_VA_STUBS)||!defined(SOMMBeforeAfter_VA_EXTERN))
  201. {
  202.     boolean result;
  203.     va_list ap;
  204.     va_start(ap, methodId);
  205.     result = SOMMBeforeAfter_sommBeforeMethod(somSelf,ev,object,methodId,ap);
  206.     va_end(ap);
  207.     return (result);
  208. }    
  209. #else
  210.     ;
  211. #endif
  212.  
  213. /*
  214.  * New Method: sommAfterMethod
  215.  */
  216. typedef void   SOMLINK somTP_SOMMBeforeAfter_sommAfterMethod(SOMMBeforeAfter *somSelf, Environment *ev,
  217.         SOMObject* object,
  218.         somId methodId,
  219.         somToken returnedvalue,
  220.         va_list ap);
  221. typedef somTP_SOMMBeforeAfter_sommAfterMethod *somTD_SOMMBeforeAfter_sommAfterMethod;
  222. #define somMD_SOMMBeforeAfter_sommAfterMethod "::SOMMBeforeAfter::sommAfterMethod"
  223. #define SOMMBeforeAfter_sommAfterMethod(somSelf,ev,object,methodId,returnedvalue,ap) \
  224.     (SOM_Resolve(somSelf, SOMMBeforeAfter, sommAfterMethod) \
  225.     (somSelf,ev,object,methodId,returnedvalue,ap))
  226.  
  227. /*
  228.  * legacy support for non-system-linkage vararg stub
  229.  * use -mnolegacy to avoid generating this stub.
  230.  */
  231. #ifdef SOMMBeforeAfter_VA_EXTERN
  232.     SOMEXTERN
  233. #else
  234.     static
  235. #endif
  236. void   va_SOMMBeforeAfter_sommAfterMethod(SOMMBeforeAfter *somSelf, Environment *ev,
  237.         SOMObject* object,
  238.         somId methodId,
  239.         somToken returnedvalue,
  240.         ...)
  241. #if (defined(SOMMBeforeAfter_VA_STUBS)||!defined(SOMMBeforeAfter_VA_EXTERN))
  242. {
  243.     va_list ap;
  244.     va_start(ap, returnedvalue);
  245.     SOMMBeforeAfter_sommAfterMethod(somSelf,ev,object,methodId,returnedvalue,ap);
  246.     va_end(ap);
  247. }    
  248. #else
  249.     ;
  250. #endif
  251.  
  252. /*
  253.  * normal vararg stubs
  254.  */
  255. #ifndef SOMGD_va_sommAfterMethod
  256.    #ifdef va_sommAfterMethod
  257.       #undef va_sommAfterMethod
  258.       #define SOMGD_va_sommAfterMethod 1
  259.    #else
  260.       #define va_sommAfterMethod somva_SOMMBeforeAfter_sommAfterMethod
  261.    #endif /* va_sommAfterMethod */
  262. #endif /* SOMGD_va_sommAfterMethod */
  263. #ifndef SOMGD_sommAfterMethod
  264.     #if (defined(_sommAfterMethod) || defined(__sommAfterMethod))
  265.         #undef _sommAfterMethod
  266.         #undef __sommAfterMethod
  267.         #define SOMGD_sommAfterMethod 1
  268.     #else
  269.         #define _sommAfterMethod somva_SOMMBeforeAfter_sommAfterMethod
  270.     #endif /* _sommAfterMethod */
  271. #endif /* SOMGD_sommAfterMethod */
  272. #ifdef SOMMBeforeAfter_VA_EXTERN
  273.     SOMEXTERN
  274. #else
  275.     static
  276. #endif
  277. void  SOMLINK somva_SOMMBeforeAfter_sommAfterMethod(SOMMBeforeAfter *somSelf, Environment *ev,
  278.         SOMObject* object,
  279.         somId methodId,
  280.         somToken returnedvalue,
  281.         ...)
  282. #if (defined(SOMMBeforeAfter_VA_STUBS)||!defined(SOMMBeforeAfter_VA_EXTERN))
  283. {
  284.     va_list ap;
  285.     va_start(ap, returnedvalue);
  286.     SOMMBeforeAfter_sommAfterMethod(somSelf,ev,object,methodId,returnedvalue,ap);
  287.     va_end(ap);
  288. }    
  289. #else
  290.     ;
  291. #endif
  292. #ifndef SOM_DONT_USE_INHERITED_MACROS
  293. #define SOMMBeforeAfter__get_somDataAlignment SOMClass__get_somDataAlignment
  294. #define SOMMBeforeAfter__get_somInstanceDataOffsets SOMClass__get_somInstanceDataOffsets
  295. #define SOMMBeforeAfter__get_somDirectInitClasses SOMClass__get_somDirectInitClasses
  296. #define SOMMBeforeAfter__set_somDirectInitClasses SOMClass__set_somDirectInitClasses
  297. #define SOMMBeforeAfter_somNew SOMClass_somNew
  298. #define SOMMBeforeAfter_somNewNoInit SOMClass_somNewNoInit
  299. #define SOMMBeforeAfter_somRenew SOMClass_somRenew
  300. #define SOMMBeforeAfter_somRenewNoInit SOMClass_somRenewNoInit
  301. #define SOMMBeforeAfter_somRenewNoZero SOMClass_somRenewNoZero
  302. #define SOMMBeforeAfter_somRenewNoInitNoZero SOMClass_somRenewNoInitNoZero
  303. #define SOMMBeforeAfter_somAllocate SOMClass_somAllocate
  304. #define SOMMBeforeAfter_somDeallocate SOMClass_somDeallocate
  305. #define SOMMBeforeAfter__get_somClassAllocate SOMClass__get_somClassAllocate
  306. #define SOMMBeforeAfter__get_somClassDeallocate SOMClass__get_somClassDeallocate
  307. #define SOMMBeforeAfter_somGetInstanceInitMask SOMClass_somGetInstanceInitMask
  308. #define SOMMBeforeAfter_somGetInstanceDestructionMask SOMClass_somGetInstanceDestructionMask
  309. #define SOMMBeforeAfter_somGetInstanceAssignmentMask SOMClass_somGetInstanceAssignmentMask
  310. #define SOMMBeforeAfter_somInitClass SOMClass_somInitClass
  311. #define SOMMBeforeAfter_somAddStaticMethod SOMClass_somAddStaticMethod
  312. #define SOMMBeforeAfter_somAddDynamicMethod SOMClass_somAddDynamicMethod
  313. #define SOMMBeforeAfter_somOverrideSMethod SOMClass_somOverrideSMethod
  314. #define SOMMBeforeAfter_somClassReady SOMClass_somClassReady
  315. #define SOMMBeforeAfter_somGetClassData SOMClass_somGetClassData
  316. #define SOMMBeforeAfter_somSetClassData SOMClass_somSetClassData
  317. #define SOMMBeforeAfter_somGetClassMtab SOMClass_somGetClassMtab
  318. #define SOMMBeforeAfter_somGetInstanceOffset SOMClass_somGetInstanceOffset
  319. #define SOMMBeforeAfter_somGetInstancePartSize SOMClass_somGetInstancePartSize
  320. #define SOMMBeforeAfter_somGetInstanceSize SOMClass_somGetInstanceSize
  321. #define SOMMBeforeAfter_somGetInstanceToken SOMClass_somGetInstanceToken
  322. #define SOMMBeforeAfter_somGetMemberToken SOMClass_somGetMemberToken
  323. #define SOMMBeforeAfter_somGetMethodData SOMClass_somGetMethodData
  324. #define SOMMBeforeAfter_somGetRdStub SOMClass_somGetRdStub
  325. #define SOMMBeforeAfter_somGetMethodDescriptor SOMClass_somGetMethodDescriptor
  326. #define SOMMBeforeAfter_somGetMethodIndex SOMClass_somGetMethodIndex
  327. #define SOMMBeforeAfter_somGetMethodToken SOMClass_somGetMethodToken
  328. #define SOMMBeforeAfter_somGetName SOMClass_somGetName
  329. #define SOMMBeforeAfter_somGetNthMethodData SOMClass_somGetNthMethodData
  330. #define SOMMBeforeAfter_somGetNthMethodInfo SOMClass_somGetNthMethodInfo
  331. #define SOMMBeforeAfter_somGetNumMethods SOMClass_somGetNumMethods
  332. #define SOMMBeforeAfter_somGetNumStaticMethods SOMClass_somGetNumStaticMethods
  333. #define SOMMBeforeAfter_somGetParent SOMClass_somGetParent
  334. #define SOMMBeforeAfter_somGetParents SOMClass_somGetParents
  335. #define SOMMBeforeAfter_somGetPClsMtab SOMClass_somGetPClsMtab
  336. #define SOMMBeforeAfter_somGetPClsMtabs SOMClass_somGetPClsMtabs
  337. #define SOMMBeforeAfter_somGetVersionNumbers SOMClass_somGetVersionNumbers
  338. #define SOMMBeforeAfter_somSetMethodDescriptor SOMClass_somSetMethodDescriptor
  339. #define SOMMBeforeAfter_somFindMethod SOMClass_somFindMethod
  340. #define SOMMBeforeAfter_somFindMethodOk SOMClass_somFindMethodOk
  341. #define SOMMBeforeAfter_somFindSMethod SOMClass_somFindSMethod
  342. #define SOMMBeforeAfter_somFindSMethodOk SOMClass_somFindSMethodOk
  343. #define SOMMBeforeAfter_somLookupMethod SOMClass_somLookupMethod
  344. #define SOMMBeforeAfter_somCheckVersion SOMClass_somCheckVersion
  345. #define SOMMBeforeAfter_somDescendedFrom SOMClass_somDescendedFrom
  346. #define SOMMBeforeAfter_somSupportsMethod SOMClass_somSupportsMethod
  347. #define SOMMBeforeAfter_somDefinedMethod SOMClass_somDefinedMethod
  348. #define SOMMBeforeAfter_somOverrideMtab SOMClass_somOverrideMtab
  349. #define SOMMBeforeAfter_somDestruct SOMObject_somDestruct
  350. #define SOMMBeforeAfter_somDefaultCopyInit SOMObject_somDefaultCopyInit
  351. #define SOMMBeforeAfter_somDefaultAssign SOMObject_somDefaultAssign
  352. #define SOMMBeforeAfter_somDefaultConstCopyInit SOMObject_somDefaultConstCopyInit
  353. #define SOMMBeforeAfter_somDefaultVCopyInit SOMObject_somDefaultVCopyInit
  354. #define SOMMBeforeAfter_somDefaultConstVCopyInit SOMObject_somDefaultConstVCopyInit
  355. #define SOMMBeforeAfter_somDefaultConstAssign SOMObject_somDefaultConstAssign
  356. #define SOMMBeforeAfter_somDefaultVAssign SOMObject_somDefaultVAssign
  357. #define SOMMBeforeAfter_somDefaultConstVAssign SOMObject_somDefaultConstVAssign
  358. #define SOMMBeforeAfter_somInit SOMObject_somInit
  359. #define SOMMBeforeAfter_somFree SOMObject_somFree
  360. #define SOMMBeforeAfter_somUninit SOMObject_somUninit
  361. #define SOMMBeforeAfter_somGetClass SOMObject_somGetClass
  362. #define SOMMBeforeAfter_somGetClassName SOMObject_somGetClassName
  363. #define SOMMBeforeAfter_somGetSize SOMObject_somGetSize
  364. #define SOMMBeforeAfter_somIsA SOMObject_somIsA
  365. #define SOMMBeforeAfter_somIsInstanceOf SOMObject_somIsInstanceOf
  366. #define SOMMBeforeAfter_somRespondsTo SOMObject_somRespondsTo
  367. #define SOMMBeforeAfter_somDispatch SOMObject_somDispatch
  368. #define SOMMBeforeAfter_somClassDispatch SOMObject_somClassDispatch
  369. #define SOMMBeforeAfter_somCastObj SOMObject_somCastObj
  370. #define SOMMBeforeAfter_somResetObj SOMObject_somResetObj
  371. #define SOMMBeforeAfter_somPrintSelf SOMObject_somPrintSelf
  372. #define SOMMBeforeAfter_somDumpSelf SOMObject_somDumpSelf
  373. #define SOMMBeforeAfter_somDumpSelfInt SOMObject_somDumpSelfInt
  374. #endif /* SOM_DONT_USE_INHERITED_MACROS */
  375.  
  376. #endif       /* SOM_SOMMBeforeAfter_h */
  377.