home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / tolkit45.zip / os2tk45 / som / include / tdict.xh < prev    next >
Text File  |  1999-02-22  |  49KB  |  1,477 lines

  1.  
  2. /*
  3.  * This file was generated by the SOM Compiler.
  4.  * FileName: tdict.xh.
  5.  * Generated using:
  6.  *     SOM Precompiler somipc: 2.29.1.17
  7.  *     SOM Emitter emitxh: 2.47
  8.  */
  9.  
  10. /*
  11.  *    COMPONENT_NAME: somuc
  12.  * 
  13.  *    ORIGINS: 82, 81, 27
  14.  * 
  15.  * 
  16.  *     25H7912  (C)  COPYRIGHT International Business Machines Corp. 1992,1996,1996
  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.  *    Copyright ⌐ 1988, 1989 Apple Computer, Inc. All rights reserved.
  23.  * 
  24.  * CLASS_NAME: somf_TDictionary
  25.  * 
  26.  * DESCRIPTION: This class represents a collection of paired objects
  27.  *              (associations).  Because dictionaries are sometimes used
  28.  *              to represent a bijective mapping, functions for retrieving a
  29.  *              key given a value are provided along with the usual access
  30.  *              functions (however, this will probably be slow).
  31.  * 
  32.  *  This file was generated by the SOM Compiler.
  33.  *  FileName: TDict.id2.
  34.  *  Generated using:
  35.  *      SOM Precompiler spc: 6.13
  36.  *      SOM Emitter emitidl.dll: 6.18
  37.  */
  38.  
  39.  
  40. #ifndef SOM_somf_TDictionary_xh
  41. #define SOM_somf_TDictionary_xh
  42.  
  43. class somf_TDictionary;
  44.  
  45. #define somf_TDictionary_MajorVersion 2
  46. #define somf_TDictionary_MinorVersion 1
  47.  
  48. /* C++ SOM defs */
  49. #include <somcls.xh>
  50. #include <somcm.xh>
  51.  
  52. /* C++ parent defs */
  53. #ifndef SOM_somf_TCollection_xh
  54. #include <tcollect.xh>
  55. #endif
  56.  
  57. #ifndef somf_TDictionary_API
  58. #define somf_TDictionary_API
  59. /*
  60.  * -- The Class API
  61.  */
  62.  
  63. /*
  64.  * Start of bindings for IDL types
  65.  */
  66.  
  67. class SOMClass;
  68. class SOMObject;
  69. class somf_TIterator;
  70. class somf_THashTable;
  71.  
  72. /*
  73.  * End of bindings for IDL types.
  74.  */
  75.  
  76. /*
  77.  * Passthru lines: File: "C.xh", "after"
  78.  */
  79.  
  80.  
  81. #include <mcollect.xh>
  82. #include <thash.xh>
  83.  
  84.  
  85. /* A procedure to create the somf_TDictionary Class */
  86. SOMEXTERN SOMClass * SOMLINK somf_TDictionaryNewClass(
  87.         integer4 majorVersion,
  88.         integer4 minorVersion);
  89.  
  90. /* The API to the somf_TDictionary class object, and the methods it introduces. */
  91. SOMEXTERN struct somf_TDictionaryClassDataStructure {
  92.     SOMClass *classObject;
  93.     somMToken somfDeleteAllKeys;
  94.     somMToken somfDeleteAllValues;
  95.     somMToken somfValueAt;
  96.     somMToken somfKeyAtMF;
  97.     somMToken somfKeyAtM;
  98.     somMToken somfDeleteKey;
  99.     somMToken somfAddKeyValuePairMMB;
  100.     somMToken somfAddKeyValuePairMM;
  101.     somMToken somfSetHashFunction;
  102.     somMToken somfGetHashFunction;
  103.     somMToken somfCreateNewImplementationFLLL;
  104.     somMToken somfCreateNewImplementationF;
  105.     somMToken somfCreateNewImplementationFL;
  106.     somMToken somfCreateNewImplementationFLL;
  107.     somMToken somfCopyImplementation;
  108.     somMToken somfAssign;
  109.     somMToken somfTDictionaryInitFLL;
  110.     somMToken somfTDictionaryInitFL;
  111.     somMToken somfTDictionaryInitF;
  112.     somMToken somfTDictionaryInitLLF;
  113.     somMToken somfTDictionaryInitLL;
  114.     somMToken somfTDictionaryInitL;
  115.     somMToken somfTDictionaryInitD;
  116. } SOMDLINK somf_TDictionaryClassData;
  117. #define _somf_TDictionary somf_TDictionaryClassData.classObject
  118.  
  119. /* The API to parentMtabs for somf_TDictionary, and the instance data it introduces. */
  120. SOMEXTERN struct somf_TDictionaryCClassDataStructure {
  121.     somMethodTabs parentMtab;
  122.     somDToken              instanceDataToken;
  123. } SOMDLINK somf_TDictionaryCClassData;
  124.  
  125. /*
  126.  * -- Typedefs for somf_TDictionary Method Procedures
  127.  */
  128. SOMEXTERN {
  129. typedef somf_TDictionary*   SOMLINK somTP_somf_TDictionary_somfTDictionaryInitFLL(somf_TDictionary *somSelf, Environment *ev, 
  130.         somf_MCollectible_somf_MCollectibleCompareFn testfn, 
  131.         long sizeHint, 
  132.         long growthRate);
  133. typedef somTP_somf_TDictionary_somfTDictionaryInitFLL *somTD_somf_TDictionary_somfTDictionaryInitFLL;
  134. typedef somf_TDictionary*   SOMLINK somTP_somf_TDictionary_somfTDictionaryInitFL(somf_TDictionary *somSelf, Environment *ev, 
  135.         somf_MCollectible_somf_MCollectibleCompareFn testfn, 
  136.         long sizeHint);
  137. typedef somTP_somf_TDictionary_somfTDictionaryInitFL *somTD_somf_TDictionary_somfTDictionaryInitFL;
  138. typedef somf_TDictionary*   SOMLINK somTP_somf_TDictionary_somfTDictionaryInitF(somf_TDictionary *somSelf, Environment *ev, 
  139.         somf_MCollectible_somf_MCollectibleCompareFn testfn);
  140. typedef somTP_somf_TDictionary_somfTDictionaryInitF *somTD_somf_TDictionary_somfTDictionaryInitF;
  141. typedef somf_TDictionary*   SOMLINK somTP_somf_TDictionary_somfTDictionaryInitLLF(somf_TDictionary *somSelf, Environment *ev, 
  142.         long sizeHint, 
  143.         long growthRate, 
  144.         somf_MCollectible_somf_MCollectibleCompareFn testfn);
  145. typedef somTP_somf_TDictionary_somfTDictionaryInitLLF *somTD_somf_TDictionary_somfTDictionaryInitLLF;
  146. typedef somf_TDictionary*   SOMLINK somTP_somf_TDictionary_somfTDictionaryInitLL(somf_TDictionary *somSelf, Environment *ev, 
  147.         long sizeHint, 
  148.         long growthRate);
  149. typedef somTP_somf_TDictionary_somfTDictionaryInitLL *somTD_somf_TDictionary_somfTDictionaryInitLL;
  150. typedef somf_TDictionary*   SOMLINK somTP_somf_TDictionary_somfTDictionaryInitL(somf_TDictionary *somSelf, Environment *ev, 
  151.         long sizeHint);
  152. typedef somTP_somf_TDictionary_somfTDictionaryInitL *somTD_somf_TDictionary_somfTDictionaryInitL;
  153. typedef somf_TDictionary*   SOMLINK somTP_somf_TDictionary_somfTDictionaryInitD(somf_TDictionary *somSelf, Environment *ev, 
  154.         somf_TDictionary* dictionary);
  155. typedef somTP_somf_TDictionary_somfTDictionaryInitD *somTD_somf_TDictionary_somfTDictionaryInitD;
  156. typedef void   SOMLINK somTP_somf_TDictionary_somfAssign(somf_TDictionary *somSelf, Environment *ev, 
  157.         somf_TDictionary* source);
  158. typedef somTP_somf_TDictionary_somfAssign *somTD_somf_TDictionary_somfAssign;
  159. typedef void   SOMLINK somTP_somf_TDictionary_somfDeleteAllKeys(somf_TDictionary *somSelf, Environment *ev);
  160. typedef somTP_somf_TDictionary_somfDeleteAllKeys *somTD_somf_TDictionary_somfDeleteAllKeys;
  161. typedef void   SOMLINK somTP_somf_TDictionary_somfDeleteAllValues(somf_TDictionary *somSelf, Environment *ev);
  162. typedef somTP_somf_TDictionary_somfDeleteAllValues *somTD_somf_TDictionary_somfDeleteAllValues;
  163. typedef somf_MCollectible*   SOMLINK somTP_somf_TDictionary_somfValueAt(somf_TDictionary *somSelf, Environment *ev, 
  164.         somf_MCollectible* key);
  165. typedef somTP_somf_TDictionary_somfValueAt *somTD_somf_TDictionary_somfValueAt;
  166. typedef somf_MCollectible*   SOMLINK somTP_somf_TDictionary_somfKeyAtMF(somf_TDictionary *somSelf, Environment *ev, 
  167.         somf_MCollectible* val, 
  168.         somf_MCollectible_somf_MCollectibleCompareFn testfn);
  169. typedef somTP_somf_TDictionary_somfKeyAtMF *somTD_somf_TDictionary_somfKeyAtMF;
  170. typedef somf_MCollectible*   SOMLINK somTP_somf_TDictionary_somfKeyAtM(somf_TDictionary *somSelf, Environment *ev, 
  171.         somf_MCollectible* val);
  172. typedef somTP_somf_TDictionary_somfKeyAtM *somTD_somf_TDictionary_somfKeyAtM;
  173. typedef somf_MCollectible*   SOMLINK somTP_somf_TDictionary_somfDeleteKey(somf_TDictionary *somSelf, Environment *ev, 
  174.         somf_MCollectible* key);
  175. typedef somTP_somf_TDictionary_somfDeleteKey *somTD_somf_TDictionary_somfDeleteKey;
  176. typedef somf_MCollectible*   SOMLINK somTP_somf_TDictionary_somfAddKeyValuePairMMB(somf_TDictionary *somSelf, Environment *ev, 
  177.         somf_MCollectible* key, 
  178.         somf_MCollectible* val, 
  179.         boolean replace);
  180. typedef somTP_somf_TDictionary_somfAddKeyValuePairMMB *somTD_somf_TDictionary_somfAddKeyValuePairMMB;
  181. typedef somf_MCollectible*   SOMLINK somTP_somf_TDictionary_somfAddKeyValuePairMM(somf_TDictionary *somSelf, Environment *ev, 
  182.         somf_MCollectible* key, 
  183.         somf_MCollectible* val);
  184. typedef somTP_somf_TDictionary_somfAddKeyValuePairMM *somTD_somf_TDictionary_somfAddKeyValuePairMM;
  185. typedef void   SOMLINK somTP_somf_TDictionary_somfSetHashFunction(somf_TDictionary *somSelf, Environment *ev, 
  186.         somf_MCollectible_somf_MCollectibleHashFn fn);
  187. typedef somTP_somf_TDictionary_somfSetHashFunction *somTD_somf_TDictionary_somfSetHashFunction;
  188. typedef somf_MCollectible_somf_MCollectibleHashFn   SOMLINK somTP_somf_TDictionary_somfGetHashFunction(somf_TDictionary *somSelf, Environment *ev);
  189. typedef somTP_somf_TDictionary_somfGetHashFunction *somTD_somf_TDictionary_somfGetHashFunction;
  190. typedef somf_THashTable*   SOMLINK somTP_somf_TDictionary_somfCreateNewImplementationFLLL(somf_TDictionary *somSelf, Environment *ev, 
  191.         somf_MCollectible_somf_MCollectibleCompareFn testfn, 
  192.         long tablesize, 
  193.         long rate, 
  194.         long threshold);
  195. typedef somTP_somf_TDictionary_somfCreateNewImplementationFLLL *somTD_somf_TDictionary_somfCreateNewImplementationFLLL;
  196. typedef somf_THashTable*   SOMLINK somTP_somf_TDictionary_somfCreateNewImplementationF(somf_TDictionary *somSelf, Environment *ev, 
  197.         somf_MCollectible_somf_MCollectibleCompareFn testfn);
  198. typedef somTP_somf_TDictionary_somfCreateNewImplementationF *somTD_somf_TDictionary_somfCreateNewImplementationF;
  199. typedef somf_THashTable*   SOMLINK somTP_somf_TDictionary_somfCreateNewImplementationFL(somf_TDictionary *somSelf, Environment *ev, 
  200.         somf_MCollectible_somf_MCollectibleCompareFn testfn, 
  201.         long tablesize);
  202. typedef somTP_somf_TDictionary_somfCreateNewImplementationFL *somTD_somf_TDictionary_somfCreateNewImplementationFL;
  203. typedef somf_THashTable*   SOMLINK somTP_somf_TDictionary_somfCreateNewImplementationFLL(somf_TDictionary *somSelf, Environment *ev, 
  204.         somf_MCollectible_somf_MCollectibleCompareFn testfn, 
  205.         long tablesize, 
  206.         long rate);
  207. typedef somTP_somf_TDictionary_somfCreateNewImplementationFLL *somTD_somf_TDictionary_somfCreateNewImplementationFLL;
  208. typedef somf_THashTable*   SOMLINK somTP_somf_TDictionary_somfCopyImplementation(somf_TDictionary *somSelf, Environment *ev);
  209. typedef somTP_somf_TDictionary_somfCopyImplementation *somTD_somf_TDictionary_somfCopyImplementation;
  210.  
  211. /*
  212.  * -- Typedefs for Reintroduced Wrapper Methods
  213.  */
  214. typedef somf_MCollectible*   SOMLINK somTP_somf_TDictionary_somfAdd(somf_TDictionary *somSelf, Environment *ev, 
  215.         somf_MCollectible* obj);
  216. typedef somTP_somf_TDictionary_somfAdd *somTD_somf_TDictionary_somfAdd;
  217. typedef void   SOMLINK somTP_somf_TDictionary_somfAddAll(somf_TDictionary *somSelf, Environment *ev, 
  218.         somf_TCollection* col);
  219. typedef somTP_somf_TDictionary_somfAddAll *somTD_somf_TDictionary_somfAddAll;
  220. typedef somf_MCollectible*   SOMLINK somTP_somf_TDictionary_somfRemove(somf_TDictionary *somSelf, Environment *ev, 
  221.         somf_MCollectible* obj);
  222. typedef somTP_somf_TDictionary_somfRemove *somTD_somf_TDictionary_somfRemove;
  223. typedef void   SOMLINK somTP_somf_TDictionary_somfRemoveAll(somf_TDictionary *somSelf, Environment *ev);
  224. typedef somTP_somf_TDictionary_somfRemoveAll *somTD_somf_TDictionary_somfRemoveAll;
  225. typedef void   SOMLINK somTP_somf_TDictionary_somfDeleteAll(somf_TDictionary *somSelf, Environment *ev);
  226. typedef somTP_somf_TDictionary_somfDeleteAll *somTD_somf_TDictionary_somfDeleteAll;
  227. typedef long   SOMLINK somTP_somf_TDictionary_somfCount(somf_TDictionary *somSelf, Environment *ev);
  228. typedef somTP_somf_TDictionary_somfCount *somTD_somf_TDictionary_somfCount;
  229. typedef somf_MCollectible*   SOMLINK somTP_somf_TDictionary_somfMember(somf_TDictionary *somSelf, Environment *ev, 
  230.         somf_MCollectible* obj);
  231. typedef somTP_somf_TDictionary_somfMember *somTD_somf_TDictionary_somfMember;
  232. typedef somf_TIterator*   SOMLINK somTP_somf_TDictionary_somfCreateIterator(somf_TDictionary *somSelf, Environment *ev);
  233. typedef somTP_somf_TDictionary_somfCreateIterator *somTD_somf_TDictionary_somfCreateIterator;
  234. typedef somf_MCollectible_somf_MCollectibleCompareFn   SOMLINK somTP_somf_TDictionary_somfTestFunction(somf_TDictionary *somSelf, Environment *ev);
  235. typedef somTP_somf_TDictionary_somfTestFunction *somTD_somf_TDictionary_somfTestFunction;
  236. typedef void   SOMLINK somTP_somf_TDictionary_somfSetTestFunction(somf_TDictionary *somSelf, Environment *ev, 
  237.         somf_MCollectible_somf_MCollectibleCompareFn testfn);
  238. typedef somTP_somf_TDictionary_somfSetTestFunction *somTD_somf_TDictionary_somfSetTestFunction;
  239. typedef somf_TCollection*   SOMLINK somTP_somf_TDictionary_somfTCollectionInit(somf_TDictionary *somSelf, Environment *ev, 
  240.         somf_MCollectible_somf_MCollectibleCompareFn testfn);
  241. typedef somTP_somf_TDictionary_somfTCollectionInit *somTD_somf_TDictionary_somfTCollectionInit;
  242. typedef boolean   SOMLINK somTP_somf_TDictionary_somfIsEqual(somf_TDictionary *somSelf, Environment *ev, 
  243.         somf_MCollectible* obj);
  244. typedef somTP_somf_TDictionary_somfIsEqual *somTD_somf_TDictionary_somfIsEqual;
  245. typedef somf_MCollectible*   SOMLINK somTP_somf_TDictionary_somfClone(somf_TDictionary *somSelf, Environment *ev);
  246. typedef somTP_somf_TDictionary_somfClone *somTD_somf_TDictionary_somfClone;
  247. typedef somf_MCollectible*   SOMLINK somTP_somf_TDictionary_somfClonePointer(somf_TDictionary *somSelf, Environment *ev, 
  248.         somf_MCollectible* clonee);
  249. typedef somTP_somf_TDictionary_somfClonePointer *somTD_somf_TDictionary_somfClonePointer;
  250. typedef long   SOMLINK somTP_somf_TDictionary_somfHash(somf_TDictionary *somSelf, Environment *ev);
  251. typedef somTP_somf_TDictionary_somfHash *somTD_somf_TDictionary_somfHash;
  252. typedef boolean   SOMLINK somTP_somf_TDictionary_somfIsSame(somf_TDictionary *somSelf, Environment *ev, 
  253.         somf_MCollectible* obj);
  254. typedef somTP_somf_TDictionary_somfIsSame *somTD_somf_TDictionary_somfIsSame;
  255. typedef boolean   SOMLINK somTP_somf_TDictionary_somfIsNotEqual(somf_TDictionary *somSelf, Environment *ev, 
  256.         somf_MCollectible* obj);
  257. typedef somTP_somf_TDictionary_somfIsNotEqual *somTD_somf_TDictionary_somfIsNotEqual;
  258. typedef void   SOMLINK somTP_somf_TDictionary_somDefaultInit(somf_TDictionary *somSelf, 
  259.         som3InitCtrl* ctrl);
  260. typedef somTP_somf_TDictionary_somDefaultInit *somTD_somf_TDictionary_somDefaultInit;
  261. typedef void   SOMLINK somTP_somf_TDictionary_somDestruct(somf_TDictionary *somSelf, 
  262.         octet doFree, 
  263.         som3DestructCtrl* ctrl);
  264. typedef somTP_somf_TDictionary_somDestruct *somTD_somf_TDictionary_somDestruct;
  265. typedef void   SOMLINK somTP_somf_TDictionary_somDefaultCopyInit(somf_TDictionary *somSelf, 
  266.         som3InitCtrl* ctrl, 
  267.         SOMObject* fromObj);
  268. typedef somTP_somf_TDictionary_somDefaultCopyInit *somTD_somf_TDictionary_somDefaultCopyInit;
  269. typedef somf_TDictionary*   SOMLINK somTP_somf_TDictionary_somDefaultAssign(somf_TDictionary *somSelf, 
  270.         som3AssignCtrl* ctrl, 
  271.         SOMObject* fromObj);
  272. typedef somTP_somf_TDictionary_somDefaultAssign *somTD_somf_TDictionary_somDefaultAssign;
  273. typedef void   SOMLINK somTP_somf_TDictionary_somDefaultConstCopyInit(somf_TDictionary *somSelf, 
  274.         som3InitCtrl* ctrl, 
  275.         SOMObject* fromObj);
  276. typedef somTP_somf_TDictionary_somDefaultConstCopyInit *somTD_somf_TDictionary_somDefaultConstCopyInit;
  277. typedef void   SOMLINK somTP_somf_TDictionary_somDefaultVCopyInit(somf_TDictionary *somSelf, 
  278.         som3InitCtrl* ctrl, 
  279.         SOMObject* fromObj);
  280. typedef somTP_somf_TDictionary_somDefaultVCopyInit *somTD_somf_TDictionary_somDefaultVCopyInit;
  281. typedef void   SOMLINK somTP_somf_TDictionary_somDefaultConstVCopyInit(somf_TDictionary *somSelf, 
  282.         som3InitCtrl* ctrl, 
  283.         SOMObject* fromObj);
  284. typedef somTP_somf_TDictionary_somDefaultConstVCopyInit *somTD_somf_TDictionary_somDefaultConstVCopyInit;
  285. typedef somf_TDictionary*   SOMLINK somTP_somf_TDictionary_somDefaultConstAssign(somf_TDictionary *somSelf, 
  286.         som3AssignCtrl* ctrl, 
  287.         SOMObject* fromObj);
  288. typedef somTP_somf_TDictionary_somDefaultConstAssign *somTD_somf_TDictionary_somDefaultConstAssign;
  289. typedef somf_TDictionary*   SOMLINK somTP_somf_TDictionary_somDefaultVAssign(somf_TDictionary *somSelf, 
  290.         som3AssignCtrl* ctrl, 
  291.         SOMObject* fromObj);
  292. typedef somTP_somf_TDictionary_somDefaultVAssign *somTD_somf_TDictionary_somDefaultVAssign;
  293. typedef somf_TDictionary*   SOMLINK somTP_somf_TDictionary_somDefaultConstVAssign(somf_TDictionary *somSelf, 
  294.         som3AssignCtrl* ctrl, 
  295.         SOMObject* fromObj);
  296. typedef somTP_somf_TDictionary_somDefaultConstVAssign *somTD_somf_TDictionary_somDefaultConstVAssign;
  297. typedef void   SOMLINK somTP_somf_TDictionary_somInit(somf_TDictionary *somSelf);
  298. typedef somTP_somf_TDictionary_somInit *somTD_somf_TDictionary_somInit;
  299. typedef void   SOMLINK somTP_somf_TDictionary_somFree(somf_TDictionary *somSelf);
  300. typedef somTP_somf_TDictionary_somFree *somTD_somf_TDictionary_somFree;
  301. typedef void   SOMLINK somTP_somf_TDictionary_somUninit(somf_TDictionary *somSelf);
  302. typedef somTP_somf_TDictionary_somUninit *somTD_somf_TDictionary_somUninit;
  303. typedef SOMClass*   SOMLINK somTP_somf_TDictionary_somGetClass(somf_TDictionary *somSelf);
  304. typedef somTP_somf_TDictionary_somGetClass *somTD_somf_TDictionary_somGetClass;
  305. typedef string   SOMLINK somTP_somf_TDictionary_somGetClassName(somf_TDictionary *somSelf);
  306. typedef somTP_somf_TDictionary_somGetClassName *somTD_somf_TDictionary_somGetClassName;
  307. typedef long   SOMLINK somTP_somf_TDictionary_somGetSize(somf_TDictionary *somSelf);
  308. typedef somTP_somf_TDictionary_somGetSize *somTD_somf_TDictionary_somGetSize;
  309. typedef boolean   SOMLINK somTP_somf_TDictionary_somIsA(somf_TDictionary *somSelf, 
  310.         SOMClass* aClassObj);
  311. typedef somTP_somf_TDictionary_somIsA *somTD_somf_TDictionary_somIsA;
  312. typedef boolean   SOMLINK somTP_somf_TDictionary_somIsInstanceOf(somf_TDictionary *somSelf, 
  313.         SOMClass* aClassObj);
  314. typedef somTP_somf_TDictionary_somIsInstanceOf *somTD_somf_TDictionary_somIsInstanceOf;
  315. typedef boolean   SOMLINK somTP_somf_TDictionary_somRespondsTo(somf_TDictionary *somSelf, 
  316.         somId mId);
  317. typedef somTP_somf_TDictionary_somRespondsTo *somTD_somf_TDictionary_somRespondsTo;
  318. typedef boolean   SOMLINK somTP_somf_TDictionary_somDispatch(somf_TDictionary *somSelf, 
  319.         somToken* retValue, 
  320.         somId methodId, 
  321.         va_list ap);
  322. typedef somTP_somf_TDictionary_somDispatch *somTD_somf_TDictionary_somDispatch;
  323. typedef boolean   SOMLINK somTP_somf_TDictionary_somClassDispatch(somf_TDictionary *somSelf, 
  324.         SOMClass* clsObj, 
  325.         somToken* retValue, 
  326.         somId methodId, 
  327.         va_list ap);
  328. typedef somTP_somf_TDictionary_somClassDispatch *somTD_somf_TDictionary_somClassDispatch;
  329. typedef boolean   SOMLINK somTP_somf_TDictionary_somCastObj(somf_TDictionary *somSelf, 
  330.         SOMClass* cls);
  331. typedef somTP_somf_TDictionary_somCastObj *somTD_somf_TDictionary_somCastObj;
  332. typedef boolean   SOMLINK somTP_somf_TDictionary_somResetObj(somf_TDictionary *somSelf);
  333. typedef somTP_somf_TDictionary_somResetObj *somTD_somf_TDictionary_somResetObj;
  334. typedef void   SOMLINK somTP_somf_TDictionary_somDispatchV(somf_TDictionary *somSelf, 
  335.         somId methodId, 
  336.         somId descriptor, 
  337.         va_list ap);
  338. typedef somTP_somf_TDictionary_somDispatchV *somTD_somf_TDictionary_somDispatchV;
  339. typedef long   SOMLINK somTP_somf_TDictionary_somDispatchL(somf_TDictionary *somSelf, 
  340.         somId methodId, 
  341.         somId descriptor, 
  342.         va_list ap);
  343. typedef somTP_somf_TDictionary_somDispatchL *somTD_somf_TDictionary_somDispatchL;
  344. typedef void*   SOMLINK somTP_somf_TDictionary_somDispatchA(somf_TDictionary *somSelf, 
  345.         somId methodId, 
  346.         somId descriptor, 
  347.         va_list ap);
  348. typedef somTP_somf_TDictionary_somDispatchA *somTD_somf_TDictionary_somDispatchA;
  349. typedef double   SOMLINK somTP_somf_TDictionary_somDispatchD(somf_TDictionary *somSelf, 
  350.         somId methodId, 
  351.         somId descriptor, 
  352.         va_list ap);
  353. typedef somTP_somf_TDictionary_somDispatchD *somTD_somf_TDictionary_somDispatchD;
  354. typedef SOMObject*   SOMLINK somTP_somf_TDictionary_somPrintSelf(somf_TDictionary *somSelf);
  355. typedef somTP_somf_TDictionary_somPrintSelf *somTD_somf_TDictionary_somPrintSelf;
  356. typedef void   SOMLINK somTP_somf_TDictionary_somDumpSelf(somf_TDictionary *somSelf, 
  357.         long level);
  358. typedef somTP_somf_TDictionary_somDumpSelf *somTD_somf_TDictionary_somDumpSelf;
  359. typedef void   SOMLINK somTP_somf_TDictionary_somDumpSelfInt(somf_TDictionary *somSelf, 
  360.         long level);
  361. typedef somTP_somf_TDictionary_somDumpSelfInt *somTD_somf_TDictionary_somDumpSelfInt;
  362. }
  363.  
  364. #endif /* somf_TDictionary_API */
  365.  
  366.  
  367. /*
  368.  * -- This emitter treats Method Tokens as Thunks by default.
  369.  * -- Use the sc modifier "nothunks" to change this default
  370.  */
  371. #undef somresolve_
  372. #define somresolve_(obj,mToken) ((somMethodProc*)((void)obj, mToken))
  373.  
  374. /*
  375.  * -- The C++ Wrapper Class for somf_TDictionary
  376.  */
  377. class somf_TDictionary : public somf_TCollection
  378. {
  379. public:
  380.  
  381. // somf_TDictionary::new creates the class object if necessary, and then uses somNewNoInit
  382. // to allocate memory and create the object. Initialization is in ctors.
  383. void *operator new(size_t)
  384. {
  385.    if (!_somf_TDictionary) somf_TDictionaryNewClass(somf_TDictionary_MajorVersion,somf_TDictionary_MinorVersion);
  386.    return (void*)
  387.       SOM_Resolve(_somf_TDictionary,SOMClass,somNewNoInit)
  388.          ((SOMClass *)((void*)_somf_TDictionary));
  389. }
  390.  
  391. // somf_TDictionary::delete uses somDestruct.
  392. void operator delete(void * obj)
  393. {
  394.    if (obj && *(void**)obj) {
  395.       SOM_Resolve(obj,SOMObject,somFree)
  396.          ((SOMObject*)obj);
  397.    }
  398. }
  399.  
  400. somf_TDictionary& operator=(somf_TDictionary& fromObj)
  401. {
  402.    this->somDefaultAssign(0,(SOMObject*)((void*)&fromObj));
  403.    return *this;
  404. }
  405.  
  406. somf_TDictionary()
  407. {
  408.    if (*(void**)this != 
  409.        ((somParentMtabStructPtr)
  410.         (somf_TDictionaryCClassData.parentMtab))->mtab)
  411.       return;
  412.    ((SOMObject*)((void*)this))->somDefaultInit(0);
  413. }
  414.  
  415. somf_TDictionary(somf_TDictionary* fromObj)
  416. {
  417.    if (*(void**)this != 
  418.        ((somParentMtabStructPtr)
  419.         (somf_TDictionaryCClassData.parentMtab))->mtab)
  420.       return;
  421.    ((SOMObject*)((void*)this))->somDefaultCopyInit(0,((SOMObject*)((void*)fromObj)));
  422. }
  423.  
  424. #ifdef __IBMCPP__
  425. #pragma info(nocnv,nopar)
  426. #endif
  427. somf_TDictionary(const somf_TDictionary* fromObj)
  428. {
  429.    if (*(void**)this != 
  430.        ((somParentMtabStructPtr)
  431.         (somf_TDictionaryCClassData.parentMtab))->mtab)
  432.       return;
  433.    ((SOMObject*)((void*)this))->somDefaultConstCopyInit(0,((SOMObject*)((void*)fromObj)));
  434. }
  435. #ifdef __IBMCPP__
  436. #pragma info(restore)
  437. #endif
  438.  
  439.  
  440. /* method: somfTDictionaryInitFLL */
  441. somf_TDictionary*   somfTDictionaryInitFLL(Environment *ev, 
  442.         somf_MCollectible_somf_MCollectibleCompareFn testfn, 
  443.         long sizeHint, 
  444.         long growthRate)
  445. {
  446. /*
  447.  *  Initializes the new dictionary.
  448.  */
  449.    return SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfTDictionaryInitFLL)
  450.     (this, ev,testfn,sizeHint,growthRate);
  451. }
  452.  
  453.  
  454. /* method: somfTDictionaryInitFL */
  455. somf_TDictionary*   somfTDictionaryInitFL(Environment *ev, 
  456.         somf_MCollectible_somf_MCollectibleCompareFn testfn, 
  457.         long sizeHint)
  458. {
  459. /*
  460.  *  Initializes the new dictionary.
  461.  */
  462.    return SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfTDictionaryInitFL)
  463.     (this, ev,testfn,sizeHint);
  464. }
  465.  
  466.  
  467. /* method: somfTDictionaryInitF */
  468. somf_TDictionary*   somfTDictionaryInitF(Environment *ev, 
  469.         somf_MCollectible_somf_MCollectibleCompareFn testfn)
  470. {
  471. /*
  472.  *  Initializes the new dictionary.
  473.  */
  474.    return SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfTDictionaryInitF)
  475.     (this, ev,testfn);
  476. }
  477.  
  478.  
  479. /* method: somfTDictionaryInitLLF */
  480. somf_TDictionary*   somfTDictionaryInitLLF(Environment *ev, 
  481.         long sizeHint, 
  482.         long growthRate, 
  483.         somf_MCollectible_somf_MCollectibleCompareFn testfn)
  484. {
  485. /*
  486.  *  Initializes the new dictionary.
  487.  */
  488.    return SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfTDictionaryInitLLF)
  489.     (this, ev,sizeHint,growthRate,testfn);
  490. }
  491.  
  492.  
  493. /* method: somfTDictionaryInitLL */
  494. somf_TDictionary*   somfTDictionaryInitLL(Environment *ev, 
  495.         long sizeHint, 
  496.         long growthRate)
  497. {
  498. /*
  499.  *  Initializes the new dictionary.
  500.  */
  501.    return SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfTDictionaryInitLL)
  502.     (this, ev,sizeHint,growthRate);
  503. }
  504.  
  505.  
  506. /* method: somfTDictionaryInitL */
  507. somf_TDictionary*   somfTDictionaryInitL(Environment *ev, 
  508.         long sizeHint)
  509. {
  510. /*
  511.  *  Initializes the new dictionary.
  512.  */
  513.    return SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfTDictionaryInitL)
  514.     (this, ev,sizeHint);
  515. }
  516.  
  517.  
  518. /* method: somfTDictionaryInitD */
  519. somf_TDictionary*   somfTDictionaryInitD(Environment *ev, 
  520.         somf_TDictionary* dictionary)
  521. {
  522. /*
  523.  *  Initializes the new dictionary.
  524.  */
  525.    return SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfTDictionaryInitD)
  526.     (this, ev,dictionary);
  527. }
  528.  
  529.  
  530. /* method: somfAssign */
  531. void   somfAssign(Environment *ev, 
  532.         somf_TDictionary* source)
  533. {
  534. /*
  535.  *  Assign the instance of this equal to the instance of source.
  536.  */
  537.    SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfAssign)
  538.     (this, ev,source);
  539. }
  540.  
  541.  
  542. /* method: somfDeleteAllKeys */
  543. void   somfDeleteAllKeys(Environment *ev)
  544. {
  545. /*
  546.  *  Remove all of the entries in the dictionary.  Reset the count to be zero.
  547.  *  Call the destructor on every key in the dictionary.
  548.  */
  549.    SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfDeleteAllKeys)
  550.     (this, ev);
  551. }
  552.  
  553.  
  554. /* method: somfDeleteAllValues */
  555. void   somfDeleteAllValues(Environment *ev)
  556. {
  557. /*
  558.  *  Remove all of the entries in the dictionary.  Reset the count to be zero.
  559.  *  Call the destructor on every value in the hash table.  If you have a value
  560.  *  which appears more than once, you will be sorry you used this method because
  561.  *  the utility classes will delete the same object more than once.  This
  562.  *  is not good.
  563.  */
  564.    SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfDeleteAllValues)
  565.     (this, ev);
  566. }
  567.  
  568.  
  569. /* method: somfValueAt */
  570. somf_MCollectible*   somfValueAt(Environment *ev, 
  571.         somf_MCollectible* key)
  572. {
  573. /*
  574.  *  Return the value associated with the key.  Return SOMF_NIL if the key could not
  575.  *  be found.
  576.  */
  577.    return SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfValueAt)
  578.     (this, ev,key);
  579. }
  580.  
  581.  
  582. /* method: somfKeyAtMF */
  583. somf_MCollectible*   somfKeyAtMF(Environment *ev, 
  584.         somf_MCollectible* val, 
  585.         somf_MCollectible_somf_MCollectibleCompareFn testfn)
  586. {
  587. /*
  588.  *  Return the first key found which has val as its value.  This involves a slow
  589.  *  search.
  590.  */
  591.    return SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfKeyAtMF)
  592.     (this, ev,val,testfn);
  593. }
  594.  
  595.  
  596. /* method: somfKeyAtM */
  597. somf_MCollectible*   somfKeyAtM(Environment *ev, 
  598.         somf_MCollectible* val)
  599. {
  600. /*
  601.  *  Return the first key found which has val as its value.  This involves a slow
  602.  *  search. This method uses the same compare function as specified in
  603.  *  the constructor.
  604.  */
  605.    return SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfKeyAtM)
  606.     (this, ev,val);
  607. }
  608.  
  609.  
  610. /* method: somfDeleteKey */
  611. somf_MCollectible*   somfDeleteKey(Environment *ev, 
  612.         somf_MCollectible* key)
  613. {
  614. /*
  615.  *  Delete the key from the key,value pair associated with key and remove the
  616.  *  key,value pair from the dictionary.  Return the value that was removed
  617.  *  as a result of this call.
  618.  */
  619.    return SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfDeleteKey)
  620.     (this, ev,key);
  621. }
  622.  
  623.  
  624. /* method: somfAddKeyValuePairMMB */
  625. somf_MCollectible*   somfAddKeyValuePairMMB(Environment *ev, 
  626.         somf_MCollectible* key, 
  627.         somf_MCollectible* val, 
  628.         boolean replace)
  629. {
  630. /*
  631.  *  If replace = FALSE, then only add key,value pair to the table if there is not
  632.  *  an existing key,value pair.  Otherwise, if replace=TRUE, add the key,value
  633.  *  pair to the hash table.  Either way, return the key that existed (if any) in
  634.  *  the hash table before this call.  Proper memory management may involve
  635.  *  checking to see if the key returned is "the same" as the key passes in when
  636.  *  replacing key,value pairs.
  637.  */
  638.    return SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfAddKeyValuePairMMB)
  639.     (this, ev,key,val,replace);
  640. }
  641.  
  642.  
  643. /* method: somfAddKeyValuePairMM */
  644. somf_MCollectible*   somfAddKeyValuePairMM(Environment *ev, 
  645.         somf_MCollectible* key, 
  646.         somf_MCollectible* val)
  647. {
  648. /*
  649.  *  Add the key,value pair to the hash table, and return the key that existed
  650.  *  (if any) in the hash table before this call.  Proper memory management may
  651.  *  involve checking to see if the key returned is "the same" as the key passes
  652.  *  in when replacing key,value pairs.
  653.  */
  654.    return SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfAddKeyValuePairMM)
  655.     (this, ev,key,val);
  656. }
  657.  
  658.  
  659. /* method: somfSetHashFunction */
  660. void   somfSetHashFunction(Environment *ev, 
  661.         somf_MCollectible_somf_MCollectibleHashFn fn)
  662. {
  663. /*
  664.  *  Set the hash function to fn.  By default this is set to MCollectible's Hash
  665.  *  (which is usually overridden in the objects you are adding to the hash
  666.  *  table).  You can use any hash function that you like as long as it has the
  667.  *  type signature of somf_MCollectibleHashFn.  Most of the time, you won't need to
  668.  *  do this.
  669.  */
  670.    SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfSetHashFunction)
  671.     (this, ev,fn);
  672. }
  673.  
  674.  
  675. /* method: somfGetHashFunction */
  676. somf_MCollectible_somf_MCollectibleHashFn   somfGetHashFunction(Environment *ev)
  677. {
  678. /*
  679.  *  Return the hash function.
  680.  */
  681.    return SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfGetHashFunction)
  682.     (this, ev);
  683. }
  684.  
  685.  
  686. /* method: somfCreateNewImplementationFLLL */
  687. somf_THashTable*   somfCreateNewImplementationFLLL(Environment *ev, 
  688.         somf_MCollectible_somf_MCollectibleCompareFn testfn, 
  689.         long tablesize, 
  690.         long rate, 
  691.         long threshold)
  692. {
  693. /*
  694.  *  Create a new hash table for the dictionary.  Normally you won't have to do
  695.  *  this.
  696.  */
  697.    return SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfCreateNewImplementationFLLL)
  698.     (this, ev,testfn,tablesize,rate,threshold);
  699. }
  700.  
  701.  
  702. /* method: somfCreateNewImplementationF */
  703. somf_THashTable*   somfCreateNewImplementationF(Environment *ev, 
  704.         somf_MCollectible_somf_MCollectibleCompareFn testfn)
  705. {
  706. /*
  707.  *  Create a new hash table for the dictionary.  Normally you won't have to do
  708.  *  this.
  709.  */
  710.    return SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfCreateNewImplementationF)
  711.     (this, ev,testfn);
  712. }
  713.  
  714.  
  715. /* method: somfCreateNewImplementationFL */
  716. somf_THashTable*   somfCreateNewImplementationFL(Environment *ev, 
  717.         somf_MCollectible_somf_MCollectibleCompareFn testfn, 
  718.         long tablesize)
  719. {
  720. /*
  721.  *  Create a new hash table for the dictionary.  Normally you won't have to do
  722.  *  this.
  723.  */
  724.    return SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfCreateNewImplementationFL)
  725.     (this, ev,testfn,tablesize);
  726. }
  727.  
  728.  
  729. /* method: somfCreateNewImplementationFLL */
  730. somf_THashTable*   somfCreateNewImplementationFLL(Environment *ev, 
  731.         somf_MCollectible_somf_MCollectibleCompareFn testfn, 
  732.         long tablesize, 
  733.         long rate)
  734. {
  735. /*
  736.  *  Create a new hash table for the dictionary.  Normally you won't have to do
  737.  *  this.
  738.  */
  739.    return SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfCreateNewImplementationFLL)
  740.     (this, ev,testfn,tablesize,rate);
  741. }
  742.  
  743.  
  744. /* method: somfCopyImplementation */
  745. somf_THashTable*   somfCopyImplementation(Environment *ev)
  746. {
  747. /*
  748.  *  Return a hash table that is a copy of the hash table in this.  Normally you
  749.  *  won't have to do this.
  750.  */
  751.    return SOM_ResolveD(this,somf_TDictionary,somf_TDictionary,somfCopyImplementation)
  752.     (this, ev);
  753. }
  754.  
  755.  
  756. /*
  757.  * Reintroduce inherited methods
  758.  */
  759.  
  760. /* method: somfAdd */
  761. somf_MCollectible*   somfAdd(Environment *ev, 
  762.         somf_MCollectible* obj)
  763. {
  764. /*
  765.  *  Add obj to this.
  766.  */
  767.    return SOM_ResolveD(this,somf_TDictionary,somf_TCollection,somfAdd)
  768.     (this, ev,obj);
  769. }
  770.  
  771.  
  772. /* method: somfAddAll */
  773. void   somfAddAll(Environment *ev, 
  774.         somf_TCollection* col)
  775. {
  776. /*
  777.  *  Add all of the objects in collection to this.  Essentially this is
  778.  *  equivalent to getting an iterator for the collection passed in and adding
  779.  *  each element in the collection to this.
  780.  */
  781.    SOM_ResolveD(this,somf_TDictionary,somf_TCollection,somfAddAll)
  782.     (this, ev,col);
  783. }
  784.  
  785.  
  786. /* method: somfRemove */
  787. somf_MCollectible*   somfRemove(Environment *ev, 
  788.         somf_MCollectible* obj)
  789. {
  790. /*
  791.  *  Remove obj from this.  Return the object which was actually removed
  792.  *  (which if you are using an IsEqual test function may not be the same as the
  793.  *  object passed in only "equal")
  794.  */
  795.    return SOM_ResolveD(this,somf_TDictionary,somf_TCollection,somfRemove)
  796.     (this, ev,obj);
  797. }
  798.  
  799.  
  800. /* method: somfRemoveAll */
  801. void   somfRemoveAll(Environment *ev)
  802. {
  803. /*
  804.  *  Remove all of the objects from this.
  805.  */
  806.    SOM_ResolveD(this,somf_TDictionary,somf_TCollection,somfRemoveAll)
  807.     (this, ev);
  808. }
  809.  
  810.  
  811. /* method: somfDeleteAll */
  812. void   somfDeleteAll(Environment *ev)
  813. {
  814. /*
  815.  *  Remove all of the objects from this and deallocate the storage that these
  816.  *  objects might have owned (that is, the destructor function is called
  817.  *  for each object in the collection).
  818.  */
  819.    SOM_ResolveD(this,somf_TDictionary,somf_TCollection,somfDeleteAll)
  820.     (this, ev);
  821. }
  822.  
  823.  
  824. /* method: somfCount */
  825. long   somfCount(Environment *ev)
  826. {
  827. /*
  828.  *  Return the number of objects in this.
  829.  */
  830.    return SOM_ResolveD(this,somf_TDictionary,somf_TCollection,somfCount)
  831.     (this, ev);
  832. }
  833.  
  834.  
  835. /* method: somfMember */
  836. somf_MCollectible*   somfMember(Environment *ev, 
  837.         somf_MCollectible* obj)
  838. {
  839. /*
  840.  *  Each object in this is compared to obj using the function testFn.  Return the
  841.  *  object for which testFn returned TRUE.  Return SOMF_NIL if not object was found.
  842.  */
  843.    return SOM_ResolveD(this,somf_TDictionary,somf_TCollection,somfMember)
  844.     (this, ev,obj);
  845. }
  846.  
  847.  
  848. /* method: somfCreateIterator */
  849. somf_TIterator*   somfCreateIterator(Environment *ev)
  850. {
  851. /*
  852.  *  This method returns a new iterator which is suitable for use in iterating
  853.  *  over the objects in this collection.
  854.  */
  855.    return SOM_ResolveD(this,somf_TDictionary,somf_TCollection,somfCreateIterator)
  856.     (this, ev);
  857. }
  858.  
  859.  
  860. /* method: somfTestFunction */
  861. somf_MCollectible_somf_MCollectibleCompareFn   somfTestFunction(Environment *ev)
  862. {
  863. /*
  864.  *  Return the test function.  This is usually either IsSame or IsEqual.
  865.  */
  866.    return SOM_ResolveD(this,somf_TDictionary,somf_TCollection,somfTestFunction)
  867.     (this, ev);
  868. }
  869.  
  870.  
  871. /* method: somfSetTestFunction */
  872. void   somfSetTestFunction(Environment *ev, 
  873.         somf_MCollectible_somf_MCollectibleCompareFn testfn)
  874. {
  875. /*
  876.  *  Set the test function.
  877.  */
  878.    SOM_ResolveD(this,somf_TDictionary,somf_TCollection,somfSetTestFunction)
  879.     (this, ev,testfn);
  880. }
  881.  
  882.  
  883. /* method: somfTCollectionInit */
  884. somf_TCollection*   somfTCollectionInit(Environment *ev, 
  885.         somf_MCollectible_somf_MCollectibleCompareFn testfn)
  886. {
  887. /*
  888.  *  Initialize the somf_TCollection test function to testfn.
  889.  */
  890.    return SOM_ResolveD(this,somf_TDictionary,somf_TCollection,somfTCollectionInit)
  891.     (this, ev,testfn);
  892. }
  893.  
  894.  
  895. /* method: somfIsEqual */
  896. boolean   somfIsEqual(Environment *ev, 
  897.         somf_MCollectible* obj)
  898. {
  899.    return SOM_ResolveD(this,somf_TDictionary,somf_MCollectible,somfIsEqual)
  900.     (this, ev,obj);
  901. }
  902.  
  903.  
  904. /* method: somfClone */
  905. somf_MCollectible*   somfClone(Environment *ev)
  906. {
  907. /*
  908.  *  somfClone provides a general function for creating a new instance of this.
  909.  */
  910.    return SOM_ResolveD(this,somf_TDictionary,somf_MCollectible,somfClone)
  911.     (this, ev);
  912. }
  913.  
  914.  
  915. /* method: somfClonePointer */
  916. somf_MCollectible*   somfClonePointer(Environment *ev, 
  917.         somf_MCollectible* clonee)
  918. {
  919. /*
  920.  *  somfClonePointer returns a pointer to a Clone
  921.  */
  922.    return SOM_ResolveD(this,somf_TDictionary,somf_MCollectible,somfClonePointer)
  923.     (this, ev,clonee);
  924. }
  925.  
  926.  
  927. /* method: somfHash */
  928. long   somfHash(Environment *ev)
  929. {
  930. /*
  931.  *  somfHash returns a value suitable for use as a hashing probe for this.
  932.  *  The default function will simply return the address of the object.
  933.  *  The default function is almost certainly not adequate if you are overriding
  934.  *  somfIsEqual because you need to make sure that all objects that "are equal"
  935.  *  to each other return the same hash value.  For example, a TText object would
  936.  *  return a hash value computed using the characters in the string instead of
  937.  *  the address of the string.
  938.  */
  939.    return SOM_ResolveD(this,somf_TDictionary,somf_MCollectible,somfHash)
  940.     (this, ev);
  941. }
  942.  
  943.  
  944. /* method: somfIsSame */
  945. boolean   somfIsSame(Environment *ev, 
  946.         somf_MCollectible* obj)
  947. {
  948. /*
  949.  *  The default function for somfIsSame is a pointer comparison
  950.  */
  951.    return SOM_ResolveD(this,somf_TDictionary,somf_MCollectible,somfIsSame)
  952.     (this, ev,obj);
  953. }
  954.  
  955.  
  956. /* method: somfIsNotEqual */
  957. boolean   somfIsNotEqual(Environment *ev, 
  958.         somf_MCollectible* obj)
  959. {
  960. /*
  961.  *  somfIsNotEqual returns TRUE if obj is NOT isomorphic to this.  It uses
  962.  *  somfIsEqual, so overriding somfIsEqual will handle the logic of somfIsNotEqual too.
  963.  */
  964.    return SOM_ResolveD(this,somf_TDictionary,somf_MCollectible,somfIsNotEqual)
  965.     (this, ev,obj);
  966. }
  967.  
  968.  
  969. /* initializer method: somDefaultInit */
  970. void   somDefaultInit(som3InitCtrl* ctrl)
  971. {
  972. /*
  973.  *  A default initializer for a SOM object. Passing a null ctrl
  974.  *  indicates to the receiver that its class is the class of the
  975.  *  object being initialized, whereby the initializer will determine
  976.  *  an appropriate control structure.
  977.  */
  978.    SOM_ResolveD(this,somf_TDictionary,SOMObject,somDefaultInit)
  979.     (this,ctrl);
  980. }
  981.  
  982.  
  983. /* method: somDestruct */
  984. void   somDestruct(octet doFree, 
  985.         som3DestructCtrl* ctrl)
  986. {
  987. /*
  988.  *  The default destructor for a SOM object. A nonzero <doFree>
  989.  *  indicates that the object storage should be freed by the
  990.  *  object's class (via somDeallocate) after uninitialization.
  991.  *  As with somDefaultInit, a null ctrl can be passed.
  992.  */
  993.    SOM_ResolveD(this,somf_TDictionary,SOMObject,somDestruct)
  994.     (this,doFree,ctrl);
  995. }
  996.  
  997.  
  998. /* initializer method: somDefaultCopyInit */
  999. void   somDefaultCopyInit(som3InitCtrl* ctrl, 
  1000.         SOMObject* fromObj)
  1001. {
  1002. /*
  1003.  *  A default copy constructor. Use this to make copies of objects for
  1004.  *  calling methods with "by-value" argument semantics.
  1005.  */
  1006.    SOM_ResolveD(this,somf_TDictionary,SOMObject,somDefaultCopyInit)
  1007.     (this,ctrl,fromObj);
  1008. }
  1009.  
  1010.  
  1011. /* method: somDefaultAssign */
  1012. somf_TDictionary*  somDefaultAssign(som3AssignCtrl* ctrl, 
  1013.         SOMObject* fromObj)
  1014. {
  1015. /*
  1016.  *  A default assignment operator. Use this to "assign" the state of one
  1017.  *  object to another.
  1018.  */
  1019.    return SOM_ResolveD(this,somf_TDictionary,SOMObject,somDefaultAssign)
  1020.     (this,ctrl,fromObj);
  1021. }
  1022.  
  1023.  
  1024. /* initializer method: somDefaultConstCopyInit */
  1025. void   somDefaultConstCopyInit(som3InitCtrl* ctrl, 
  1026.         SOMObject* fromObj)
  1027. {
  1028. /*
  1029.  *  A default copy constructor that uses a const fromObj.
  1030.  */
  1031.    SOM_ResolveD(this,somf_TDictionary,SOMObject,somDefaultConstCopyInit)
  1032.     (this,ctrl,fromObj);
  1033. }
  1034.  
  1035.  
  1036. /* initializer method: somDefaultVCopyInit */
  1037. void   somDefaultVCopyInit(som3InitCtrl* ctrl, 
  1038.         SOMObject* fromObj)
  1039. {
  1040. /*
  1041.  *  A default copy constructor that uses a volatile fromObj.
  1042.  */
  1043.    SOM_ResolveD(this,somf_TDictionary,SOMObject,somDefaultVCopyInit)
  1044.     (this,ctrl,fromObj);
  1045. }
  1046.  
  1047.  
  1048. /* initializer method: somDefaultConstVCopyInit */
  1049. void   somDefaultConstVCopyInit(som3InitCtrl* ctrl, 
  1050.         SOMObject* fromObj)
  1051. {
  1052. /*
  1053.  *  A default copy constructor that uses a const volatile fromObj.
  1054.  */
  1055.    SOM_ResolveD(this,somf_TDictionary,SOMObject,somDefaultConstVCopyInit)
  1056.     (this,ctrl,fromObj);
  1057. }
  1058.  
  1059.  
  1060. /* method: somDefaultConstAssign */
  1061. somf_TDictionary*  somDefaultConstAssign(som3AssignCtrl* ctrl, 
  1062.         SOMObject* fromObj)
  1063. {
  1064. /*
  1065.  *  A default assignment operator that uses a const fromObj.
  1066.  */
  1067.    return SOM_ResolveD(this,somf_TDictionary,SOMObject,somDefaultConstAssign)
  1068.     (this,ctrl,fromObj);
  1069. }
  1070.  
  1071.  
  1072. /* method: somDefaultVAssign */
  1073. somf_TDictionary*  somDefaultVAssign(som3AssignCtrl* ctrl, 
  1074.         SOMObject* fromObj)
  1075. {
  1076. /*
  1077.  *  A default assignment operator that uses a volatile fromObj.
  1078.  */
  1079.    return SOM_ResolveD(this,somf_TDictionary,SOMObject,somDefaultVAssign)
  1080.     (this,ctrl,fromObj);
  1081. }
  1082.  
  1083.  
  1084. /* method: somDefaultConstVAssign */
  1085. somf_TDictionary*  somDefaultConstVAssign(som3AssignCtrl* ctrl, 
  1086.         SOMObject* fromObj)
  1087. {
  1088. /*
  1089.  *  A default assignment operator that uses a const volatile fromObj.
  1090.  */
  1091.    return SOM_ResolveD(this,somf_TDictionary,SOMObject,somDefaultConstVAssign)
  1092.     (this,ctrl,fromObj);
  1093. }
  1094.  
  1095.  
  1096. /* method: somInit */
  1097. void   somInit()
  1098. {
  1099. /*
  1100.  *  Obsolete but still supported. Override somDefaultInit instead of somInit.
  1101.  */
  1102.    SOM_ResolveD(this,somf_TDictionary,SOMObject,somInit)
  1103.     (this);
  1104. }
  1105.  
  1106.  
  1107. /* method: somFree */
  1108. void   somFree()
  1109. {
  1110. /*
  1111.  *  Use as directed by framework implementations.
  1112.  */
  1113.    SOM_ResolveD(this,somf_TDictionary,SOMObject,somFree)
  1114.     (this);
  1115. }
  1116.  
  1117.  
  1118. /* method: somUninit */
  1119. void   somUninit()
  1120. {
  1121. /*
  1122.  *  Obsolete but still supported. Override somDestruct instead of somUninit.
  1123.  */
  1124.    SOM_ResolveD(this,somf_TDictionary,SOMObject,somUninit)
  1125.     (this);
  1126. }
  1127.  
  1128.  
  1129. /* method: somGetClass */
  1130. SOMClass*   somGetClass()
  1131. {
  1132. /*
  1133.  *  Return the receiver's class.
  1134.  */
  1135.    return SOM_ResolveD(this,somf_TDictionary,SOMObject,somGetClass)
  1136.     (this);
  1137. }
  1138.  
  1139.  
  1140. /* method: somGetClassName */
  1141. string   somGetClassName()
  1142. {
  1143. /*
  1144.  *  Return the name of the receiver's class.
  1145.  */
  1146.    return SOM_ResolveD(this,somf_TDictionary,SOMObject,somGetClassName)
  1147.     (this);
  1148. }
  1149.  
  1150.  
  1151. /* method: somGetSize */
  1152. long   somGetSize()
  1153. {
  1154. /*
  1155.  *  Return the size of the receiver.
  1156.  */
  1157.    return SOM_ResolveD(this,somf_TDictionary,SOMObject,somGetSize)
  1158.     (this);
  1159. }
  1160.  
  1161.  
  1162. /* method: somIsA */
  1163. boolean   somIsA(SOMClass* aClassObj)
  1164. {
  1165. /*
  1166.  *  Returns 1 (true) if the receiver responds to methods
  1167.  *  introduced by <aClassObj>, and 0 (false) otherwise.
  1168.  */
  1169.    return SOM_ResolveD(this,somf_TDictionary,SOMObject,somIsA)
  1170.     (this,aClassObj);
  1171. }
  1172.  
  1173.  
  1174. /* method: somIsInstanceOf */
  1175. boolean   somIsInstanceOf(SOMClass* aClassObj)
  1176. {
  1177. /*
  1178.  *  Returns 1 (true) if the receiver is an instance of
  1179.  *  <aClassObj> and 0 (false) otherwise.
  1180.  */
  1181.    return SOM_ResolveD(this,somf_TDictionary,SOMObject,somIsInstanceOf)
  1182.     (this,aClassObj);
  1183. }
  1184.  
  1185.  
  1186. /* method: somRespondsTo */
  1187. boolean   somRespondsTo(somId mId)
  1188. {
  1189. /*
  1190.  *  Returns 1 (true) if the indicated method can be invoked
  1191.  *  on the receiver and 0 (false) otherwise.
  1192.  */
  1193.    return SOM_ResolveD(this,somf_TDictionary,SOMObject,somRespondsTo)
  1194.     (this,mId);
  1195. }
  1196.  
  1197.  
  1198. /* va_list method: somDispatch */
  1199.  
  1200. /*
  1201.  *  This method provides a generic, class-specific dispatch mechanism.
  1202.  *  It accepts as input <retValue> a pointer to the memory area to be
  1203.  *  loaded with the result of dispatching the method indicated by
  1204.  *  <methodId> using the arguments in <ap>. <ap> contains the object
  1205.  *  on which the method is to be invoked as the first argument.
  1206.  */
  1207. /* the va_list invocation form */
  1208. boolean   somf_TDictionary_somDispatch(somToken* retValue, 
  1209.         somId methodId, 
  1210.         va_list ap)
  1211. {return SOM_ResolveD(this,somf_TDictionary,SOMObject,somDispatch)
  1212.     (this,retValue,methodId,ap);
  1213. }
  1214.  
  1215. /* the varargs invocation form */
  1216. boolean   somDispatch(somToken* retValue, 
  1217.         somId methodId, 
  1218.         ...)
  1219. {
  1220. /*
  1221.  *  This method provides a generic, class-specific dispatch mechanism.
  1222.  *  It accepts as input <retValue> a pointer to the memory area to be
  1223.  *  loaded with the result of dispatching the method indicated by
  1224.  *  <methodId> using the arguments in <ap>. <ap> contains the object
  1225.  *  on which the method is to be invoked as the first argument.
  1226.  */
  1227.    va_list ap;
  1228.    va_start(ap, methodId);
  1229.    boolean __somResult = 
  1230.       SOM_ResolveD(this,somf_TDictionary,SOMObject,somDispatch)
  1231.     (this,retValue,methodId,ap);
  1232.    va_end(ap);
  1233.    return __somResult;
  1234. }
  1235.  
  1236.  
  1237. /* va_list method: somClassDispatch */
  1238.  
  1239. /*
  1240.  *  Like somDispatch, but method resolution for static methods is done
  1241.  *  according to the clsObj instance method table.
  1242.  */
  1243. /* the va_list invocation form */
  1244. boolean   somf_TDictionary_somClassDispatch(SOMClass* clsObj, 
  1245.         somToken* retValue, 
  1246.         somId methodId, 
  1247.         va_list ap)
  1248. {return SOM_ResolveD(this,somf_TDictionary,SOMObject,somClassDispatch)
  1249.     (this,clsObj,retValue,methodId,ap);
  1250. }
  1251.  
  1252. /* the varargs invocation form */
  1253. boolean   somClassDispatch(SOMClass* clsObj, 
  1254.         somToken* retValue, 
  1255.         somId methodId, 
  1256.         ...)
  1257. {
  1258. /*
  1259.  *  Like somDispatch, but method resolution for static methods is done
  1260.  *  according to the clsObj instance method table.
  1261.  */
  1262.    va_list ap;
  1263.    va_start(ap, methodId);
  1264.    boolean __somResult = 
  1265.       SOM_ResolveD(this,somf_TDictionary,SOMObject,somClassDispatch)
  1266.     (this,clsObj,retValue,methodId,ap);
  1267.    va_end(ap);
  1268.    return __somResult;
  1269. }
  1270.  
  1271.  
  1272. /* method: somCastObj */
  1273. boolean   somCastObj(SOMClass* cls)
  1274. {
  1275. /*
  1276.  *  cast the receiving object to cls (which must be an ancestor of the
  1277.  *  objects true class. Returns true on success.
  1278.  */
  1279.    return SOM_ResolveD(this,somf_TDictionary,SOMObject,somCastObj)
  1280.     (this,cls);
  1281. }
  1282.  
  1283.  
  1284. /* method: somResetObj */
  1285. boolean   somResetObj()
  1286. {
  1287. /*
  1288.  *  reset an object to its true class. Returns true always.
  1289.  */
  1290.    return SOM_ResolveD(this,somf_TDictionary,SOMObject,somResetObj)
  1291.     (this);
  1292. }
  1293.  
  1294.  
  1295. /* va_list method: somDispatchV */
  1296.  
  1297. /*
  1298.  *  Obsolete. Use somDispatch instead.
  1299.  */
  1300. /* the va_list invocation form */
  1301. void   somf_TDictionary_somDispatchV(somId methodId, 
  1302.         somId descriptor, 
  1303.         va_list ap)
  1304. {   SOM_ResolveD(this,somf_TDictionary,SOMObject,somDispatchV)
  1305.     (this,methodId,descriptor,ap);
  1306. }
  1307.  
  1308. /* the varargs invocation form */
  1309. void   somDispatchV(somId methodId, 
  1310.         somId descriptor, 
  1311.         ...)
  1312. {
  1313. /*
  1314.  *  Obsolete. Use somDispatch instead.
  1315.  */
  1316.    va_list ap;
  1317.    va_start(ap, descriptor);
  1318.    SOM_ResolveD(this,somf_TDictionary,SOMObject,somDispatchV)
  1319.     (this,methodId,descriptor,ap);
  1320.    va_end(ap);
  1321. }
  1322.  
  1323.  
  1324. /* va_list method: somDispatchL */
  1325.  
  1326. /*
  1327.  *  Obsolete. Use somDispatch instead.
  1328.  */
  1329. /* the va_list invocation form */
  1330. long   somf_TDictionary_somDispatchL(somId methodId, 
  1331.         somId descriptor, 
  1332.         va_list ap)
  1333. {return SOM_ResolveD(this,somf_TDictionary,SOMObject,somDispatchL)
  1334.     (this,methodId,descriptor,ap);
  1335. }
  1336.  
  1337. /* the varargs invocation form */
  1338. long   somDispatchL(somId methodId, 
  1339.         somId descriptor, 
  1340.         ...)
  1341. {
  1342. /*
  1343.  *  Obsolete. Use somDispatch instead.
  1344.  */
  1345.    va_list ap;
  1346.    va_start(ap, descriptor);
  1347.    long __somResult = 
  1348.       SOM_ResolveD(this,somf_TDictionary,SOMObject,somDispatchL)
  1349.     (this,methodId,descriptor,ap);
  1350.    va_end(ap);
  1351.    return __somResult;
  1352. }
  1353.  
  1354.  
  1355. /* va_list method: somDispatchA */
  1356.  
  1357. /*
  1358.  *  Obsolete. Use somDispatch instead.
  1359.  */
  1360. /* the va_list invocation form */
  1361. void*   somf_TDictionary_somDispatchA(somId methodId, 
  1362.         somId descriptor, 
  1363.         va_list ap)
  1364. {return SOM_ResolveD(this,somf_TDictionary,SOMObject,somDispatchA)
  1365.     (this,methodId,descriptor,ap);
  1366. }
  1367.  
  1368. /* the varargs invocation form */
  1369. void*   somDispatchA(somId methodId, 
  1370.         somId descriptor, 
  1371.         ...)
  1372. {
  1373. /*
  1374.  *  Obsolete. Use somDispatch instead.
  1375.  */
  1376.    va_list ap;
  1377.    va_start(ap, descriptor);
  1378.    void* __somResult = 
  1379.       SOM_ResolveD(this,somf_TDictionary,SOMObject,somDispatchA)
  1380.     (this,methodId,descriptor,ap);
  1381.    va_end(ap);
  1382.    return __somResult;
  1383. }
  1384.  
  1385.  
  1386. /* va_list method: somDispatchD */
  1387.  
  1388. /*
  1389.  *  Obsolete. Use somDispatch instead.
  1390.  */
  1391. /* the va_list invocation form */
  1392. double   somf_TDictionary_somDispatchD(somId methodId, 
  1393.         somId descriptor, 
  1394.         va_list ap)
  1395. {return SOM_ResolveD(this,somf_TDictionary,SOMObject,somDispatchD)
  1396.     (this,methodId,descriptor,ap);
  1397. }
  1398.  
  1399. /* the varargs invocation form */
  1400. double   somDispatchD(somId methodId, 
  1401.         somId descriptor, 
  1402.         ...)
  1403. {
  1404. /*
  1405.  *  Obsolete. Use somDispatch instead.
  1406.  */
  1407.    va_list ap;
  1408.    va_start(ap, descriptor);
  1409.    double __somResult = 
  1410.       SOM_ResolveD(this,somf_TDictionary,SOMObject,somDispatchD)
  1411.     (this,methodId,descriptor,ap);
  1412.    va_end(ap);
  1413.    return __somResult;
  1414. }
  1415.  
  1416.  
  1417. /* method: somPrintSelf */
  1418. SOMObject*   somPrintSelf()
  1419. {
  1420. /*
  1421.  *  Uses <SOMOutCharRoutine> to write a brief string with identifying
  1422.  *  information about this object.  The default implementation just gives
  1423.  *  the object's class name and its address in memory.
  1424.  *  <self> is returned.
  1425.  */
  1426.    return SOM_ResolveD(this,somf_TDictionary,SOMObject,somPrintSelf)
  1427.     (this);
  1428. }
  1429.  
  1430.  
  1431. /* method: somDumpSelf */
  1432. void   somDumpSelf(long level)
  1433. {
  1434. /*
  1435.  *  Uses <SOMOutCharRoutine> to write a detailed description of this object
  1436.  *  and its current state.
  1437.  * 
  1438.  *  <level> indicates the nesting level for describing compound objects
  1439.  *  it must be greater than or equal to zero.  All lines in the
  1440.  *  description will be preceeded by <2*level> spaces.
  1441.  * 
  1442.  *  This routine only actually writes the data that concerns the object
  1443.  *  as a whole, such as class, and uses <somDumpSelfInt> to describe
  1444.  *  the object's current state.  This approach allows readable
  1445.  *  descriptions of compound objects to be constructed.
  1446.  * 
  1447.  *  Generally it is not necessary to override this method, if it is
  1448.  *  overriden it generally must be completely replaced.
  1449.  */
  1450.    SOM_ResolveD(this,somf_TDictionary,SOMObject,somDumpSelf)
  1451.     (this,level);
  1452. }
  1453.  
  1454.  
  1455. /* method: somDumpSelfInt */
  1456. void   somDumpSelfInt(long level)
  1457. {
  1458. /*
  1459.  *  Uses <SOMOutCharRoutine> to write in the current state of this object.
  1460.  *  Generally this method will need to be overridden.  When overriding
  1461.  *  it, begin by calling the parent class form of this method and then
  1462.  *  write in a description of your class's instance data. This will
  1463.  *  result in a description of all the object's instance data going
  1464.  *  from its root ancestor class to its specific class.
  1465.  */
  1466.    SOM_ResolveD(this,somf_TDictionary,SOMObject,somDumpSelfInt)
  1467.     (this,level);
  1468. }
  1469.  
  1470.  
  1471.  
  1472. };   /* somf_TDictionary */
  1473.  
  1474.  
  1475.  
  1476. #endif       /* SOM_somf_TDictionary_xh */
  1477.