home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / tolkit45.zip / os2tk45 / som / include / sctmplt.h < prev    next >
C/C++ Source or Header  |  1999-02-22  |  32KB  |  760 lines

  1.  
  2. /*
  3.  * This file was generated by the SOM Compiler.
  4.  * FileName: sctmplt.h.
  5.  * Generated using:
  6.  *     SOM Precompiler somipc: 2.29.1.17
  7.  *     SOM Emitter emith: 2.47
  8.  */
  9.  
  10. /*
  11.  *    COMPONENT_NAME: some
  12.  * 
  13.  *    ORIGINS: 27
  14.  * 
  15.  * 
  16.  *    10H9767, 10H9769  (C) COPYRIGHT International Business Machines Corp. 1992,1994
  17.  *    All Rights Reserved
  18.  *    Licensed Materials - Property of IBM
  19.  *    US Government Users Restricted Rights - Use, duplication or
  20.  *    disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
  21.  * 
  22.  */
  23.  
  24.  
  25. #ifndef SOM_SOMTTemplateOutputC_h
  26. #define SOM_SOMTTemplateOutputC_h
  27.  
  28.  
  29. /*
  30.  * Passthru lines: File: "C.h", "before"
  31.  */
  32. #include <stdio.h>
  33. typedef enum somtCommentStyleT { somtDashesE, somtCPPE, somtCSimpleE, somtCBlockE } somtCommentStyleT;
  34.  
  35. #include <som.h>
  36.  
  37. /*
  38.  * -- This emitter treats Method Tokens as Thunks by default.
  39.  * -- Use the sc modifier "nothunks" to change this default
  40.  */
  41. #undef somresolve_
  42. #define somresolve_(obj,mToken) ((somMethodProc*)((void)obj, mToken))
  43.  
  44. /*
  45.  * Define the class name as an object type
  46.  */
  47. #ifndef SOMTTemplateOutputC
  48. #define SOMTTemplateOutputC SOMObject
  49. #endif
  50. #include <somobj.h>
  51.  
  52. /*
  53.  * Start of bindings for IDL types
  54.  */
  55.  
  56. #ifndef SOMClass
  57.     #define SOMClass SOMObject
  58. #endif /* SOMClass */
  59. #ifndef SOMStringTableC
  60.     #define SOMStringTableC SOMObject
  61. #endif /* SOMStringTableC */
  62. #define SOMTTemplateOutputC_MAX_INPUT_LINE_LENGTH 1024 /* 1024 */
  63. #define SOMTTemplateOutputC_MAX_OUTPUT_LINE_LENGTH 4096 /* 4096 */
  64.  
  65. #ifndef SOM_DONT_USE_SHORT_NAMES
  66. #ifndef SOMTGD_MAX_INPUT_LINE_LENGTH
  67.     #ifdef MAX_INPUT_LINE_LENGTH
  68.         #undef MAX_INPUT_LINE_LENGTH
  69.         #define SOMTGD_MAX_INPUT_LINE_LENGTH 1
  70.     #else
  71.         #define MAX_INPUT_LINE_LENGTH SOMTTemplateOutputC_MAX_INPUT_LINE_LENGTH
  72.     #endif /* MAX_INPUT_LINE_LENGTH */
  73. #endif /* SOMTGD_MAX_INPUT_LINE_LENGTH */
  74. #ifndef SOMTGD_MAX_OUTPUT_LINE_LENGTH
  75.     #ifdef MAX_OUTPUT_LINE_LENGTH
  76.         #undef MAX_OUTPUT_LINE_LENGTH
  77.         #define SOMTGD_MAX_OUTPUT_LINE_LENGTH 1
  78.     #else
  79.         #define MAX_OUTPUT_LINE_LENGTH SOMTTemplateOutputC_MAX_OUTPUT_LINE_LENGTH
  80.     #endif /* MAX_OUTPUT_LINE_LENGTH */
  81. #endif /* SOMTGD_MAX_OUTPUT_LINE_LENGTH */
  82. #endif /* SOM_DONT_USE_SHORT_NAMES */
  83.  
  84. /*
  85.  * End of bindings for IDL types.
  86.  */
  87.  
  88. #define SOMTTemplateOutputC_MajorVersion 2
  89. #define SOMTTemplateOutputC_MinorVersion 1
  90.  
  91. /*
  92.  * External name shortening if required
  93.  */
  94. #ifdef SOM_USE_SHORT_EXTERNAL_NAMES
  95. #define SOMTTemplateOutputCNewClass c
  96. #pragma linkage(c, system)
  97. #define SOMTTemplateOutputCClassData d
  98. #define SOMTTemplateOutputCCClassData x
  99. #endif /* SOM_USE_SHORT_EXTERNAL_NAMES */
  100. /*--------------Migration------------*/
  101. #define SOMTTemplateOutputC_classObj SOMTTemplateOutputCClassData.classObject
  102. #define _SOMTTemplateOutputC SOMTTemplateOutputC_classObj
  103.  
  104. /*
  105.  * Declare the class creation procedure
  106.  */
  107. SOMEXTERN SOMClass * SOMLINK SOMTTemplateOutputCNewClass(integer4 somtmajorVersion,
  108.         integer4 somtminorVersion);
  109. #pragma linkage(SOMTTemplateOutputCNewClass, system)
  110.  
  111. /*
  112.  * Declare the class data structure
  113.  */
  114. SOMEXTERN struct SOMTTemplateOutputCClassDataStructure {
  115.     SOMClass *classObject;
  116.     somMToken _get_somtCommentStyle;
  117.     somMToken _set_somtCommentStyle;
  118.     somMToken _get_somtLineLength;
  119.     somMToken _set_somtLineLength;
  120.     somMToken _set_somtCommentNewline;
  121.     somMToken _get_somtCommentNewline;
  122.     somMToken somtGetSymbol;
  123.     somMToken somtSetSymbol;
  124.     somMToken somtSetSymbolCopyName;
  125.     somMToken somtSetSymbolCopyValue;
  126.     somMToken somtSetSymbolCopyBoth;
  127.     somMToken somtCheckSymbol;
  128.     somMToken somtSetOutputFile;
  129.     somMToken somto;
  130.     somMToken somtOutputComment;
  131.     somMToken somtOutputSection;
  132.     somMToken somtAddSectionDefinitions;
  133.     somMToken somtReadSectionDefinitions;
  134.     somMToken somtExpandSymbol;
  135. } SOMDLINK SOMTTemplateOutputCClassData;
  136.  
  137. /*
  138.  * Declare the C specific class data structure
  139.  */
  140. SOMEXTERN struct SOMTTemplateOutputCCClassDataStructure {
  141.     somMethodTabs parentMtab;
  142.     somDToken instanceDataToken;
  143. } SOMDLINK SOMTTemplateOutputCCClassData;
  144.  
  145. /*
  146.  * New and Renew macros for SOMTTemplateOutputC
  147.  */
  148. #define SOMTTemplateOutputCNew() \
  149.    ( _SOMTTemplateOutputC ? \
  150.     _somNew(_SOMTTemplateOutputC) \
  151.     : ( SOMTTemplateOutputCNewClass(\
  152.         SOMTTemplateOutputC_MajorVersion, \
  153.         SOMTTemplateOutputC_MinorVersion),\
  154.        _somNew(_SOMTTemplateOutputC)))
  155. #define SOMTTemplateOutputCRenew(buf) \
  156.    ( _SOMTTemplateOutputC ? \
  157.     _somRenew(_SOMTTemplateOutputC, buf) \
  158.     : ( SOMTTemplateOutputCNewClass(\
  159.         SOMTTemplateOutputC_MajorVersion, \
  160.         SOMTTemplateOutputC_MinorVersion),\
  161.        _somRenew(_SOMTTemplateOutputC, buf)))
  162.  
  163. /*
  164.  * Override method: somInit
  165.  */
  166. #define SOMTTemplateOutputC_somInit(somSelf) \
  167.     SOMObject_somInit(somSelf)
  168.  
  169. /*
  170.  * Override method: somUninit
  171.  */
  172. #define SOMTTemplateOutputC_somUninit(somSelf) \
  173.     SOMObject_somUninit(somSelf)
  174.  
  175. /*
  176.  * Override method: somPrintSelf
  177.  */
  178. #define SOMTTemplateOutputC_somPrintSelf(somSelf) \
  179.     SOMObject_somPrintSelf(somSelf)
  180.  
  181. /*
  182.  * Override method: somDumpSelfInt
  183.  */
  184. #define SOMTTemplateOutputC_somDumpSelfInt(somSelf,level) \
  185.     SOMObject_somDumpSelfInt(somSelf,level)
  186.  
  187. /*
  188.  * New Method: _get_somtCommentStyle
  189.  */
  190. typedef somtCommentStyleT   SOMLINK somTP_SOMTTemplateOutputC__get_somtCommentStyle(SOMTTemplateOutputC *somSelf);
  191. #pragma linkage(somTP_SOMTTemplateOutputC__get_somtCommentStyle, system)
  192. typedef somTP_SOMTTemplateOutputC__get_somtCommentStyle *somTD_SOMTTemplateOutputC__get_somtCommentStyle;
  193. /*
  194.  *  Controls the style in which comments are wrtten as follows:
  195.  *    somtDashesE: "--" at the start of each line
  196.  *    somtCPPE: C++ style, "//" at the start of each line
  197.  *    somtCSimpleE: simple C style, each line wrapped in / * and * /
  198.  *    somtCBlockE: block C style, block style, ie leading / * then a * on each
  199.  *               line and then a final * /
  200.  */
  201. #define somMD_SOMTTemplateOutputC__get_somtCommentStyle "::SOMTTemplateOutputC::_get_somtCommentStyle"
  202. #define SOMTTemplateOutputC__get_somtCommentStyle(somSelf) \
  203.     (SOM_Resolve(somSelf, SOMTTemplateOutputC, _get_somtCommentStyle) \
  204.     (somSelf))
  205. #ifndef SOMGD_get_somtCommentStyle
  206.     #if (defined(_get_somtCommentStyle) || defined(__get_somtCommentStyle))
  207.         #undef _get_somtCommentStyle
  208.         #undef __get_somtCommentStyle
  209.         #define SOMGD_get_somtCommentStyle 1
  210.     #else
  211.         #define __get_somtCommentStyle SOMTTemplateOutputC__get_somtCommentStyle
  212.     #endif /* __get_somtCommentStyle */
  213. #endif /* SOMGD_get_somtCommentStyle */
  214.  
  215. /*
  216.  * New Method: _set_somtCommentStyle
  217.  */
  218. typedef void   SOMLINK somTP_SOMTTemplateOutputC__set_somtCommentStyle(SOMTTemplateOutputC *somSelf, 
  219.         somtCommentStyleT somtCommentStyle);
  220. #pragma linkage(somTP_SOMTTemplateOutputC__set_somtCommentStyle, system)
  221. typedef somTP_SOMTTemplateOutputC__set_somtCommentStyle *somTD_SOMTTemplateOutputC__set_somtCommentStyle;
  222. /*
  223.  *  Controls the style in which comments are wrtten as follows:
  224.  *    somtDashesE: "--" at the start of each line
  225.  *    somtCPPE: C++ style, "//" at the start of each line
  226.  *    somtCSimpleE: simple C style, each line wrapped in / * and * /
  227.  *    somtCBlockE: block C style, block style, ie leading / * then a * on each
  228.  *               line and then a final * /
  229.  */
  230. #define somMD_SOMTTemplateOutputC__set_somtCommentStyle "::SOMTTemplateOutputC::_set_somtCommentStyle"
  231. #define SOMTTemplateOutputC__set_somtCommentStyle(somSelf,somtCommentStyle) \
  232.     (SOM_Resolve(somSelf, SOMTTemplateOutputC, _set_somtCommentStyle) \
  233.     (somSelf,somtCommentStyle))
  234. #ifndef SOMGD_set_somtCommentStyle
  235.     #if (defined(_set_somtCommentStyle) || defined(__set_somtCommentStyle))
  236.         #undef _set_somtCommentStyle
  237.         #undef __set_somtCommentStyle
  238.         #define SOMGD_set_somtCommentStyle 1
  239.     #else
  240.         #define __set_somtCommentStyle SOMTTemplateOutputC__set_somtCommentStyle
  241.     #endif /* __set_somtCommentStyle */
  242. #endif /* SOMGD_set_somtCommentStyle */
  243.  
  244. /*
  245.  * New Method: _get_somtLineLength
  246.  */
  247. typedef long   SOMLINK somTP_SOMTTemplateOutputC__get_somtLineLength(SOMTTemplateOutputC *somSelf);
  248. #pragma linkage(somTP_SOMTTemplateOutputC__get_somtLineLength, system)
  249. typedef somTP_SOMTTemplateOutputC__get_somtLineLength *somTD_SOMTTemplateOutputC__get_somtLineLength;
  250. /*
  251.  *  Controls list output only.  Default is 72.
  252.  *  At least one list item will be output on each line, so making
  253.  *  this value very short will cause list items to be placed on
  254.  *  separate lines.
  255.  */
  256. #define somMD_SOMTTemplateOutputC__get_somtLineLength "::SOMTTemplateOutputC::_get_somtLineLength"
  257. #define SOMTTemplateOutputC__get_somtLineLength(somSelf) \
  258.     (SOM_Resolve(somSelf, SOMTTemplateOutputC, _get_somtLineLength) \
  259.     (somSelf))
  260. #ifndef SOMGD_get_somtLineLength
  261.     #if (defined(_get_somtLineLength) || defined(__get_somtLineLength))
  262.         #undef _get_somtLineLength
  263.         #undef __get_somtLineLength
  264.         #define SOMGD_get_somtLineLength 1
  265.     #else
  266.         #define __get_somtLineLength SOMTTemplateOutputC__get_somtLineLength
  267.     #endif /* __get_somtLineLength */
  268. #endif /* SOMGD_get_somtLineLength */
  269.  
  270. /*
  271.  * New Method: _set_somtLineLength
  272.  */
  273. typedef void   SOMLINK somTP_SOMTTemplateOutputC__set_somtLineLength(SOMTTemplateOutputC *somSelf, 
  274.         long somtLineLength);
  275. #pragma linkage(somTP_SOMTTemplateOutputC__set_somtLineLength, system)
  276. typedef somTP_SOMTTemplateOutputC__set_somtLineLength *somTD_SOMTTemplateOutputC__set_somtLineLength;
  277. /*
  278.  *  Controls list output only.  Default is 72.
  279.  *  At least one list item will be output on each line, so making
  280.  *  this value very short will cause list items to be placed on
  281.  *  separate lines.
  282.  */
  283. #define somMD_SOMTTemplateOutputC__set_somtLineLength "::SOMTTemplateOutputC::_set_somtLineLength"
  284. #define SOMTTemplateOutputC__set_somtLineLength(somSelf,somtLineLength) \
  285.     (SOM_Resolve(somSelf, SOMTTemplateOutputC, _set_somtLineLength) \
  286.     (somSelf,somtLineLength))
  287. #ifndef SOMGD_set_somtLineLength
  288.     #if (defined(_set_somtLineLength) || defined(__set_somtLineLength))
  289.         #undef _set_somtLineLength
  290.         #undef __set_somtLineLength
  291.         #define SOMGD_set_somtLineLength 1
  292.     #else
  293.         #define __set_somtLineLength SOMTTemplateOutputC__set_somtLineLength
  294.     #endif /* __set_somtLineLength */
  295. #endif /* SOMGD_set_somtLineLength */
  296.  
  297. /*
  298.  * New Method: _get_somtCommentNewline
  299.  */
  300. typedef boolean   SOMLINK somTP_SOMTTemplateOutputC__get_somtCommentNewline(SOMTTemplateOutputC *somSelf);
  301. #pragma linkage(somTP_SOMTTemplateOutputC__get_somtCommentNewline, system)
  302. typedef somTP_SOMTTemplateOutputC__get_somtCommentNewline *somTD_SOMTTemplateOutputC__get_somtCommentNewline;
  303. /*
  304.  * Method from the IDL attribute statement:
  305.  * "attribute boolean somtCommentNewline"
  306.  */
  307. #define somMD_SOMTTemplateOutputC__get_somtCommentNewline "::SOMTTemplateOutputC::_get_somtCommentNewline"
  308. #define SOMTTemplateOutputC__get_somtCommentNewline(somSelf) \
  309.     (SOM_Resolve(somSelf, SOMTTemplateOutputC, _get_somtCommentNewline) \
  310.     (somSelf))
  311. #ifndef SOMGD_get_somtCommentNewline
  312.     #if (defined(_get_somtCommentNewline) || defined(__get_somtCommentNewline))
  313.         #undef _get_somtCommentNewline
  314.         #undef __get_somtCommentNewline
  315.         #define SOMGD_get_somtCommentNewline 1
  316.     #else
  317.         #define __get_somtCommentNewline SOMTTemplateOutputC__get_somtCommentNewline
  318.     #endif /* __get_somtCommentNewline */
  319. #endif /* SOMGD_get_somtCommentNewline */
  320.  
  321. /*
  322.  * New Method: _set_somtCommentNewline
  323.  */
  324. typedef void   SOMLINK somTP_SOMTTemplateOutputC__set_somtCommentNewline(SOMTTemplateOutputC *somSelf, 
  325.         boolean somtCommentNewline);
  326. #pragma linkage(somTP_SOMTTemplateOutputC__set_somtCommentNewline, system)
  327. typedef somTP_SOMTTemplateOutputC__set_somtCommentNewline *somTD_SOMTTemplateOutputC__set_somtCommentNewline;
  328. /*
  329.  * Method from the IDL attribute statement:
  330.  * "attribute boolean somtCommentNewline"
  331.  */
  332. #define somMD_SOMTTemplateOutputC__set_somtCommentNewline "::SOMTTemplateOutputC::_set_somtCommentNewline"
  333. #define SOMTTemplateOutputC__set_somtCommentNewline(somSelf,somtCommentNewline) \
  334.     (SOM_Resolve(somSelf, SOMTTemplateOutputC, _set_somtCommentNewline) \
  335.     (somSelf,somtCommentNewline))
  336. #ifndef SOMGD_set_somtCommentNewline
  337.     #if (defined(_set_somtCommentNewline) || defined(__set_somtCommentNewline))
  338.         #undef _set_somtCommentNewline
  339.         #undef __set_somtCommentNewline
  340.         #define SOMGD_set_somtCommentNewline 1
  341.     #else
  342.         #define __set_somtCommentNewline SOMTTemplateOutputC__set_somtCommentNewline
  343.     #endif /* __set_somtCommentNewline */
  344. #endif /* SOMGD_set_somtCommentNewline */
  345.  
  346. /*
  347.  * New Method: somtGetSymbol
  348.  */
  349. typedef string   SOMLINK somTP_SOMTTemplateOutputC_somtGetSymbol(SOMTTemplateOutputC *somSelf, 
  350.         string name);
  351. #pragma linkage(somTP_SOMTTemplateOutputC_somtGetSymbol, system)
  352. typedef somTP_SOMTTemplateOutputC_somtGetSymbol *somTD_SOMTTemplateOutputC_somtGetSymbol;
  353. /*
  354.  *  Returns the value associated with <name>.  If no value is
  355.  *  associated with <name> then NULL is returned
  356.  */
  357. #define somMD_SOMTTemplateOutputC_somtGetSymbol "::SOMTTemplateOutputC::somtGetSymbol"
  358. #define SOMTTemplateOutputC_somtGetSymbol(somSelf,name) \
  359.     (SOM_Resolve(somSelf, SOMTTemplateOutputC, somtGetSymbol) \
  360.     (somSelf,name))
  361. #ifndef SOMGD_somtGetSymbol
  362.     #if (defined(_somtGetSymbol) || defined(__somtGetSymbol))
  363.         #undef _somtGetSymbol
  364.         #undef __somtGetSymbol
  365.         #define SOMGD_somtGetSymbol 1
  366.     #else
  367.         #define _somtGetSymbol SOMTTemplateOutputC_somtGetSymbol
  368.     #endif /* _somtGetSymbol */
  369. #endif /* SOMGD_somtGetSymbol */
  370.  
  371. /*
  372.  * New Method: somtSetSymbol
  373.  */
  374. typedef void   SOMLINK somTP_SOMTTemplateOutputC_somtSetSymbol(SOMTTemplateOutputC *somSelf, 
  375.         string name, 
  376.         string value);
  377. #pragma linkage(somTP_SOMTTemplateOutputC_somtSetSymbol, system)
  378. typedef somTP_SOMTTemplateOutputC_somtSetSymbol *somTD_SOMTTemplateOutputC_somtSetSymbol;
  379. /*
  380.  *  Makes the symbol with name <name> have value <value>.  This will
  381.  *  overwrite any previous value the symbol had, and add the symbol
  382.  *  if necessary.
  383.  *  Takes over ownership of both name and value.
  384.  */
  385. #define somMD_SOMTTemplateOutputC_somtSetSymbol "::SOMTTemplateOutputC::somtSetSymbol"
  386. #define SOMTTemplateOutputC_somtSetSymbol(somSelf,name,value) \
  387.     (SOM_Resolve(somSelf, SOMTTemplateOutputC, somtSetSymbol) \
  388.     (somSelf,name,value))
  389. #ifndef SOMGD_somtSetSymbol
  390.     #if (defined(_somtSetSymbol) || defined(__somtSetSymbol))
  391.         #undef _somtSetSymbol
  392.         #undef __somtSetSymbol
  393.         #define SOMGD_somtSetSymbol 1
  394.     #else
  395.         #define _somtSetSymbol SOMTTemplateOutputC_somtSetSymbol
  396.     #endif /* _somtSetSymbol */
  397. #endif /* SOMGD_somtSetSymbol */
  398.  
  399. /*
  400.  * New Method: somtSetSymbolCopyName
  401.  */
  402. typedef void   SOMLINK somTP_SOMTTemplateOutputC_somtSetSymbolCopyName(SOMTTemplateOutputC *somSelf, 
  403.         string name, 
  404.         string value);
  405. #pragma linkage(somTP_SOMTTemplateOutputC_somtSetSymbolCopyName, system)
  406. typedef somTP_SOMTTemplateOutputC_somtSetSymbolCopyName *somTD_SOMTTemplateOutputC_somtSetSymbolCopyName;
  407. /*
  408.  *  See somtSetSymbol
  409.  *  Only takes over ownership of value.
  410.  */
  411. #define somMD_SOMTTemplateOutputC_somtSetSymbolCopyName "::SOMTTemplateOutputC::somtSetSymbolCopyName"
  412. #define SOMTTemplateOutputC_somtSetSymbolCopyName(somSelf,name,value) \
  413.     (SOM_Resolve(somSelf, SOMTTemplateOutputC, somtSetSymbolCopyName) \
  414.     (somSelf,name,value))
  415. #ifndef SOMGD_somtSetSymbolCopyName
  416.     #if (defined(_somtSetSymbolCopyName) || defined(__somtSetSymbolCopyName))
  417.         #undef _somtSetSymbolCopyName
  418.         #undef __somtSetSymbolCopyName
  419.         #define SOMGD_somtSetSymbolCopyName 1
  420.     #else
  421.         #define _somtSetSymbolCopyName SOMTTemplateOutputC_somtSetSymbolCopyName
  422.     #endif /* _somtSetSymbolCopyName */
  423. #endif /* SOMGD_somtSetSymbolCopyName */
  424.  
  425. /*
  426.  * New Method: somtSetSymbolCopyValue
  427.  */
  428. typedef void   SOMLINK somTP_SOMTTemplateOutputC_somtSetSymbolCopyValue(SOMTTemplateOutputC *somSelf, 
  429.         string name, 
  430.         string value);
  431. #pragma linkage(somTP_SOMTTemplateOutputC_somtSetSymbolCopyValue, system)
  432. typedef somTP_SOMTTemplateOutputC_somtSetSymbolCopyValue *somTD_SOMTTemplateOutputC_somtSetSymbolCopyValue;
  433. /*
  434.  *  See somtSetSymbol
  435.  *  Only takes over ownership of name.
  436.  */
  437. #define somMD_SOMTTemplateOutputC_somtSetSymbolCopyValue "::SOMTTemplateOutputC::somtSetSymbolCopyValue"
  438. #define SOMTTemplateOutputC_somtSetSymbolCopyValue(somSelf,name,value) \
  439.     (SOM_Resolve(somSelf, SOMTTemplateOutputC, somtSetSymbolCopyValue) \
  440.     (somSelf,name,value))
  441. #ifndef SOMGD_somtSetSymbolCopyValue
  442.     #if (defined(_somtSetSymbolCopyValue) || defined(__somtSetSymbolCopyValue))
  443.         #undef _somtSetSymbolCopyValue
  444.         #undef __somtSetSymbolCopyValue
  445.         #define SOMGD_somtSetSymbolCopyValue 1
  446.     #else
  447.         #define _somtSetSymbolCopyValue SOMTTemplateOutputC_somtSetSymbolCopyValue
  448.     #endif /* _somtSetSymbolCopyValue */
  449. #endif /* SOMGD_somtSetSymbolCopyValue */
  450.  
  451. /*
  452.  * New Method: somtSetSymbolCopyBoth
  453.  */
  454. typedef void   SOMLINK somTP_SOMTTemplateOutputC_somtSetSymbolCopyBoth(SOMTTemplateOutputC *somSelf, 
  455.         string name, 
  456.         string value);
  457. #pragma linkage(somTP_SOMTTemplateOutputC_somtSetSymbolCopyBoth, system)
  458. typedef somTP_SOMTTemplateOutputC_somtSetSymbolCopyBoth *somTD_SOMTTemplateOutputC_somtSetSymbolCopyBoth;
  459. /*
  460.  *  See somtSetSymbol
  461.  *  Does not take over ownership of either <name> or <value>
  462.  */
  463. #define somMD_SOMTTemplateOutputC_somtSetSymbolCopyBoth "::SOMTTemplateOutputC::somtSetSymbolCopyBoth"
  464. #define SOMTTemplateOutputC_somtSetSymbolCopyBoth(somSelf,name,value) \
  465.     (SOM_Resolve(somSelf, SOMTTemplateOutputC, somtSetSymbolCopyBoth) \
  466.     (somSelf,name,value))
  467. #ifndef SOMGD_somtSetSymbolCopyBoth
  468.     #if (defined(_somtSetSymbolCopyBoth) || defined(__somtSetSymbolCopyBoth))
  469.         #undef _somtSetSymbolCopyBoth
  470.         #undef __somtSetSymbolCopyBoth
  471.         #define SOMGD_somtSetSymbolCopyBoth 1
  472.     #else
  473.         #define _somtSetSymbolCopyBoth SOMTTemplateOutputC_somtSetSymbolCopyBoth
  474.     #endif /* _somtSetSymbolCopyBoth */
  475. #endif /* SOMGD_somtSetSymbolCopyBoth */
  476.  
  477. /*
  478.  * New Method: somtCheckSymbol
  479.  */
  480. typedef boolean   SOMLINK somTP_SOMTTemplateOutputC_somtCheckSymbol(SOMTTemplateOutputC *somSelf, 
  481.         string name);
  482. #pragma linkage(somTP_SOMTTemplateOutputC_somtCheckSymbol, system)
  483. typedef somTP_SOMTTemplateOutputC_somtCheckSymbol *somTD_SOMTTemplateOutputC_somtCheckSymbol;
  484. /*
  485.  *  Returns 1 (true) if the indicated symbol has non-null, non-zero
  486.  *  length value, and 0 (false) otherwise.
  487.  */
  488. #define somMD_SOMTTemplateOutputC_somtCheckSymbol "::SOMTTemplateOutputC::somtCheckSymbol"
  489. #define SOMTTemplateOutputC_somtCheckSymbol(somSelf,name) \
  490.     (SOM_Resolve(somSelf, SOMTTemplateOutputC, somtCheckSymbol) \
  491.     (somSelf,name))
  492. #ifndef SOMGD_somtCheckSymbol
  493.     #if (defined(_somtCheckSymbol) || defined(__somtCheckSymbol))
  494.         #undef _somtCheckSymbol
  495.         #undef __somtCheckSymbol
  496.         #define SOMGD_somtCheckSymbol 1
  497.     #else
  498.         #define _somtCheckSymbol SOMTTemplateOutputC_somtCheckSymbol
  499.     #endif /* _somtCheckSymbol */
  500. #endif /* SOMGD_somtCheckSymbol */
  501.  
  502. /*
  503.  * New Method: somtSetOutputFile
  504.  */
  505. typedef void   SOMLINK somTP_SOMTTemplateOutputC_somtSetOutputFile(SOMTTemplateOutputC *somSelf, 
  506.         FILE* fp);
  507. #pragma linkage(somTP_SOMTTemplateOutputC_somtSetOutputFile, system)
  508. typedef somTP_SOMTTemplateOutputC_somtSetOutputFile *somTD_SOMTTemplateOutputC_somtSetOutputFile;
  509. /*
  510.  *  All template output will be directed to <fp>. Default is <stdout>.
  511.  */
  512. #define somMD_SOMTTemplateOutputC_somtSetOutputFile "::SOMTTemplateOutputC::somtSetOutputFile"
  513. #define SOMTTemplateOutputC_somtSetOutputFile(somSelf,fp) \
  514.     (SOM_Resolve(somSelf, SOMTTemplateOutputC, somtSetOutputFile) \
  515.     (somSelf,fp))
  516. #ifndef SOMGD_somtSetOutputFile
  517.     #if (defined(_somtSetOutputFile) || defined(__somtSetOutputFile))
  518.         #undef _somtSetOutputFile
  519.         #undef __somtSetOutputFile
  520.         #define SOMGD_somtSetOutputFile 1
  521.     #else
  522.         #define _somtSetOutputFile SOMTTemplateOutputC_somtSetOutputFile
  523.     #endif /* _somtSetOutputFile */
  524. #endif /* SOMGD_somtSetOutputFile */
  525.  
  526. /*
  527.  * New Method: somto
  528.  */
  529. typedef void   SOMLINK somTP_SOMTTemplateOutputC_somto(SOMTTemplateOutputC *somSelf, 
  530.         string tmplt);
  531. #pragma linkage(somTP_SOMTTemplateOutputC_somto, system)
  532. typedef somTP_SOMTTemplateOutputC_somto *somTD_SOMTTemplateOutputC_somto;
  533. /*
  534.  *  Outputs a template, <tmplt>, after substitution for any symbols
  535.  *  that occur in it.  Five substitutions are supported: simple,
  536.  *  list, comment, tab, and conditional.
  537.  *  Substitutable items in the template are bracketed with angle
  538.  *  brackets. (Backslash can be used to escape an angle bracket.)
  539.  *  Simple substitutions just replace a symbol with its value. If
  540.  *  the symbol has no value in this template object then the symbol
  541.  *  is replaced error string but no error is raised.
  542.  *  List substitution assumes that the symbol has a value in output
  543.  *  template list form. This is a newline separated string of
  544.  *  values. The list substitution specification consists of four
  545.  *  parts, a prefix, a symbol, a separator, and a list indicator.
  546.  *  prefixes and separators can only be composed of blanks, comma,
  547.  *  colons, and semi-colons.  The list indicator is "..." (three
  548.  *  periods).  For example, the list substitution
  549.  *  specification "<, name, ...> has a prefix of ", ", a symbol of
  550.  *  "name" and a separator of ", ".  The prefix will be used
  551.  *  whenever there is at least one item in the list and the separator
  552.  *  will be used between any two list items.  After the first items
  553.  *  of a list is placed each additional item is evaluated to see if
  554.  *  it would begin after the line length limit (set by
  555.  *  _set_somtLineLength), if it would then a new line is begun and the
  556.  *  value is placed directly under the first item.
  557.  *  Comment substitution assumes that the symbol has a value in
  558.  *  output template list form.  A comment specification consists of
  559.  *  a comment indicator followed by a symbol name. The comment
  560.  *  indicator is "--".  Eg, <-- classComment> is a valid comment
  561.  *  substitution specification.  The lines of the comment are output
  562.  *  according to the current comment style (see <somtCommentStyle>)
  563.  *  and alined with the starting column of the comment
  564.  *  specification.
  565.  *  Tab substitution is specified by <@dd> where "dd" is a valid
  566.  *  positive integer. Blanks will be inserted into the output stream
  567.  *  if necessary to position the next character of output at the
  568.  *  column indicated by "dd".
  569.  *  Conditional substitution is specified by puting a question mark,
  570.  *  "?", in column one of the template line.  The line will not be
  571.  *  output at all unless at least one valid, non-blank,  symbol
  572.  *  substitution  occurs on the line.
  573.  */
  574. #define somMD_SOMTTemplateOutputC_somto "::SOMTTemplateOutputC::somto"
  575. #define SOMTTemplateOutputC_somto(somSelf,tmplt) \
  576.     (SOM_Resolve(somSelf, SOMTTemplateOutputC, somto) \
  577.     (somSelf,tmplt))
  578. #ifndef SOMGD_somto
  579.     #if (defined(_somto) || defined(__somto))
  580.         #undef _somto
  581.         #undef __somto
  582.         #define SOMGD_somto 1
  583.     #else
  584.         #define _somto SOMTTemplateOutputC_somto
  585.     #endif /* _somto */
  586. #endif /* SOMGD_somto */
  587.  
  588. /*
  589.  * New Method: somtOutputComment
  590.  */
  591. typedef void   SOMLINK somTP_SOMTTemplateOutputC_somtOutputComment(SOMTTemplateOutputC *somSelf, 
  592.         string comment);
  593. #pragma linkage(somTP_SOMTTemplateOutputC_somtOutputComment, system)
  594. typedef somTP_SOMTTemplateOutputC_somtOutputComment *somTD_SOMTTemplateOutputC_somtOutputComment;
  595. /*
  596.  *  Inserts a comment into the output stream.  <comment> must be a
  597.  *  string containing the comment with lines in the comment
  598.  *  seperated by newlines.
  599.  *  The style of output is controlled by <somtCommentStyle>
  600.  */
  601. #define somMD_SOMTTemplateOutputC_somtOutputComment "::SOMTTemplateOutputC::somtOutputComment"
  602. #define SOMTTemplateOutputC_somtOutputComment(somSelf,comment) \
  603.     (SOM_Resolve(somSelf, SOMTTemplateOutputC, somtOutputComment) \
  604.     (somSelf,comment))
  605. #ifndef SOMGD_somtOutputComment
  606.     #if (defined(_somtOutputComment) || defined(__somtOutputComment))
  607.         #undef _somtOutputComment
  608.         #undef __somtOutputComment
  609.         #define SOMGD_somtOutputComment 1
  610.     #else
  611.         #define _somtOutputComment SOMTTemplateOutputC_somtOutputComment
  612.     #endif /* _somtOutputComment */
  613. #endif /* SOMGD_somtOutputComment */
  614.  
  615. /*
  616.  * New Method: somtOutputSection
  617.  */
  618. typedef void   SOMLINK somTP_SOMTTemplateOutputC_somtOutputSection(SOMTTemplateOutputC *somSelf, 
  619.         string sectionName);
  620. #pragma linkage(somTP_SOMTTemplateOutputC_somtOutputSection, system)
  621. typedef somTP_SOMTTemplateOutputC_somtOutputSection *somTD_SOMTTemplateOutputC_somtOutputSection;
  622. /*
  623.  *  Just like <somto> above, except <sectionName> must be a symbol
  624.  *  whose value will be used as the template.
  625.  */
  626. #define somMD_SOMTTemplateOutputC_somtOutputSection "::SOMTTemplateOutputC::somtOutputSection"
  627. #define SOMTTemplateOutputC_somtOutputSection(somSelf,sectionName) \
  628.     (SOM_Resolve(somSelf, SOMTTemplateOutputC, somtOutputSection) \
  629.     (somSelf,sectionName))
  630. #ifndef SOMGD_somtOutputSection
  631.     #if (defined(_somtOutputSection) || defined(__somtOutputSection))
  632.         #undef _somtOutputSection
  633.         #undef __somtOutputSection
  634.         #define SOMGD_somtOutputSection 1
  635.     #else
  636.         #define _somtOutputSection SOMTTemplateOutputC_somtOutputSection
  637.     #endif /* _somtOutputSection */
  638. #endif /* SOMGD_somtOutputSection */
  639.  
  640. /*
  641.  * New Method: somtAddSectionDefinitions
  642.  */
  643. typedef void   SOMLINK somTP_SOMTTemplateOutputC_somtAddSectionDefinitions(SOMTTemplateOutputC *somSelf, 
  644.         string defString);
  645. #pragma linkage(somTP_SOMTTemplateOutputC_somtAddSectionDefinitions, system)
  646. typedef somTP_SOMTTemplateOutputC_somtAddSectionDefinitions *somTD_SOMTTemplateOutputC_somtAddSectionDefinitions;
  647. /*
  648.  *  <defString> must be a string of the form:
  649.  *  :section1
  650.  *  value 1 line 1
  651.  *  value 1 line 2
  652.  *  :section2
  653.  *  value 2 line 1
  654.  *  :section3
  655.  *  value 3 line 1
  656.  *  Where the lines that contain a ":" in column 1 immediately followed
  657.  *  by a single name are used to intro the start of a new section.
  658.  *  The section is named by the name on the colon line.  A backslash
  659.  *  can be used to escape a colon in column one that is not supposed
  660.  *  to start a new section.
  661.  *  Adds the indicated section definitions to this template.
  662.  */
  663. #define somMD_SOMTTemplateOutputC_somtAddSectionDefinitions "::SOMTTemplateOutputC::somtAddSectionDefinitions"
  664. #define SOMTTemplateOutputC_somtAddSectionDefinitions(somSelf,defString) \
  665.     (SOM_Resolve(somSelf, SOMTTemplateOutputC, somtAddSectionDefinitions) \
  666.     (somSelf,defString))
  667. #ifndef SOMGD_somtAddSectionDefinitions
  668.     #if (defined(_somtAddSectionDefinitions) || defined(__somtAddSectionDefinitions))
  669.         #undef _somtAddSectionDefinitions
  670.         #undef __somtAddSectionDefinitions
  671.         #define SOMGD_somtAddSectionDefinitions 1
  672.     #else
  673.         #define _somtAddSectionDefinitions SOMTTemplateOutputC_somtAddSectionDefinitions
  674.     #endif /* _somtAddSectionDefinitions */
  675. #endif /* SOMGD_somtAddSectionDefinitions */
  676.  
  677. /*
  678.  * New Method: somtReadSectionDefinitions
  679.  */
  680. typedef void   SOMLINK somTP_SOMTTemplateOutputC_somtReadSectionDefinitions(SOMTTemplateOutputC *somSelf, 
  681.         FILE* fp);
  682. #pragma linkage(somTP_SOMTTemplateOutputC_somtReadSectionDefinitions, system)
  683. typedef somTP_SOMTTemplateOutputC_somtReadSectionDefinitions *somTD_SOMTTemplateOutputC_somtReadSectionDefinitions;
  684. /*
  685.  *  Reads section definitions from the indicated file.  The section
  686.  *  definitions must be in the form defined above in
  687.  *  <somtAddSectionDefinitions>.
  688.  */
  689. #define somMD_SOMTTemplateOutputC_somtReadSectionDefinitions "::SOMTTemplateOutputC::somtReadSectionDefinitions"
  690. #define SOMTTemplateOutputC_somtReadSectionDefinitions(somSelf,fp) \
  691.     (SOM_Resolve(somSelf, SOMTTemplateOutputC, somtReadSectionDefinitions) \
  692.     (somSelf,fp))
  693. #ifndef SOMGD_somtReadSectionDefinitions
  694.     #if (defined(_somtReadSectionDefinitions) || defined(__somtReadSectionDefinitions))
  695.         #undef _somtReadSectionDefinitions
  696.         #undef __somtReadSectionDefinitions
  697.         #define SOMGD_somtReadSectionDefinitions 1
  698.     #else
  699.         #define _somtReadSectionDefinitions SOMTTemplateOutputC_somtReadSectionDefinitions
  700.     #endif /* _somtReadSectionDefinitions */
  701. #endif /* SOMGD_somtReadSectionDefinitions */
  702.  
  703. /*
  704.  * New Method: somtExpandSymbol
  705.  */
  706. typedef string   SOMLINK somTP_SOMTTemplateOutputC_somtExpandSymbol(SOMTTemplateOutputC *somSelf, 
  707.         string s, 
  708.         string buf);
  709. #pragma linkage(somTP_SOMTTemplateOutputC_somtExpandSymbol, system)
  710. typedef somTP_SOMTTemplateOutputC_somtExpandSymbol *somTD_SOMTTemplateOutputC_somtExpandSymbol;
  711. /*
  712.  *  Expands simple symbols in an already expanded string.  Thus if you
  713.  *  have a symbol which is itself a Section in a template file, and this
  714.  *  section could have other sections in it then you should call this
  715.  *  method.
  716.  */
  717. #define somMD_SOMTTemplateOutputC_somtExpandSymbol "::SOMTTemplateOutputC::somtExpandSymbol"
  718. #define SOMTTemplateOutputC_somtExpandSymbol(somSelf,s,buf) \
  719.     (SOM_Resolve(somSelf, SOMTTemplateOutputC, somtExpandSymbol) \
  720.     (somSelf,s,buf))
  721. #ifndef SOMGD_somtExpandSymbol
  722.     #if (defined(_somtExpandSymbol) || defined(__somtExpandSymbol))
  723.         #undef _somtExpandSymbol
  724.         #undef __somtExpandSymbol
  725.         #define SOMGD_somtExpandSymbol 1
  726.     #else
  727.         #define _somtExpandSymbol SOMTTemplateOutputC_somtExpandSymbol
  728.     #endif /* _somtExpandSymbol */
  729. #endif /* SOMGD_somtExpandSymbol */
  730. #ifndef SOM_DONT_USE_INHERITED_MACROS
  731. #define SOMTTemplateOutputC_somDefaultInit SOMObject_somDefaultInit
  732. #define SOMTTemplateOutputC_somDestruct SOMObject_somDestruct
  733. #define SOMTTemplateOutputC_somDefaultCopyInit SOMObject_somDefaultCopyInit
  734. #define SOMTTemplateOutputC_somDefaultAssign SOMObject_somDefaultAssign
  735. #define SOMTTemplateOutputC_somDefaultConstCopyInit SOMObject_somDefaultConstCopyInit
  736. #define SOMTTemplateOutputC_somDefaultVCopyInit SOMObject_somDefaultVCopyInit
  737. #define SOMTTemplateOutputC_somDefaultConstVCopyInit SOMObject_somDefaultConstVCopyInit
  738. #define SOMTTemplateOutputC_somDefaultConstAssign SOMObject_somDefaultConstAssign
  739. #define SOMTTemplateOutputC_somDefaultVAssign SOMObject_somDefaultVAssign
  740. #define SOMTTemplateOutputC_somDefaultConstVAssign SOMObject_somDefaultConstVAssign
  741. #define SOMTTemplateOutputC_somFree SOMObject_somFree
  742. #define SOMTTemplateOutputC_somGetClass SOMObject_somGetClass
  743. #define SOMTTemplateOutputC_somGetClassName SOMObject_somGetClassName
  744. #define SOMTTemplateOutputC_somGetSize SOMObject_somGetSize
  745. #define SOMTTemplateOutputC_somIsA SOMObject_somIsA
  746. #define SOMTTemplateOutputC_somIsInstanceOf SOMObject_somIsInstanceOf
  747. #define SOMTTemplateOutputC_somRespondsTo SOMObject_somRespondsTo
  748. #define SOMTTemplateOutputC_somDispatch SOMObject_somDispatch
  749. #define SOMTTemplateOutputC_somClassDispatch SOMObject_somClassDispatch
  750. #define SOMTTemplateOutputC_somCastObj SOMObject_somCastObj
  751. #define SOMTTemplateOutputC_somResetObj SOMObject_somResetObj
  752. #define SOMTTemplateOutputC_somDispatchV SOMObject_somDispatchV
  753. #define SOMTTemplateOutputC_somDispatchL SOMObject_somDispatchL
  754. #define SOMTTemplateOutputC_somDispatchA SOMObject_somDispatchA
  755. #define SOMTTemplateOutputC_somDispatchD SOMObject_somDispatchD
  756. #define SOMTTemplateOutputC_somDumpSelf SOMObject_somDumpSelf
  757. #endif /* SOM_DONT_USE_INHERITED_MACROS */
  758.  
  759. #endif       /* SOM_SOMTTemplateOutputC_h */
  760.