home *** CD-ROM | disk | FTP | other *** search
/ Power GUI Programming with VisualAge C++ / powergui.iso / trialva / ibmcppw / samples / som / somd / cpp / dii / foo.cpp < prev    next >
Encoding:
C/C++ Source or Header  |  1996-01-24  |  1.5 KB  |  63 lines

  1. //
  2. //   COMPONENT_NAME: somx
  3. //
  4. //   ORIGINS: 27
  5. //
  6. //
  7. //   10H9767, 10H9769  (C) COPYRIGHT International Business Machines Corp. 1992,1994
  8. //   All Rights Reserved
  9. //   Licensed Materials - Property of IBM
  10. //   US Government Users Restricted Rights - Use, duplication or
  11. //   disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
  12. //
  13.  
  14. /* %Z% %I% %W% %G% %U% [%H% %T%] */
  15. /*
  16.  *  This file was generated by the SOM Compiler and Emitter Framework.
  17.  *  Generated using: 
  18.  *      SOM Emitter emitxtm: 2.37
  19.  */
  20.  
  21. #ifndef SOM_Module_foo_Source
  22. #define SOM_Module_foo_Source
  23. #endif
  24. #define Foo_Class_Source
  25.  
  26. #include <somdtype.xh>
  27. #include "foo.xih"
  28.  
  29. SOMEXTERN void SOMLINK SOMInitModule(long majorVersion, long minorVersion)
  30. {
  31.    FooNewClass(0, 0);
  32. }
  33.  
  34. SOM_Scope string  SOMLINK method1(Foo *somSelf,  Environment *ev, 
  35.                                   string* a, long* b, _IDL_SEQUENCE_octet *c)
  36. {
  37.     /* FooData *somThis = FooGetData(somSelf); */
  38.     FooMethodDebug("Foo","method1");
  39.  
  40.     /* set return value for out string parameter */
  41.      *a = "abc";
  42.  
  43.     /* set return value for inout long parameter */
  44.      *b =  c->_maximum + *b;
  45.  
  46.     /* return results */
  47.      return("method1 completed");
  48. }
  49.  
  50. #ifndef _WIN32
  51. #include <windows.h>
  52. int CALLBACK LibMain (HINSTANCE inst, WORD ds, WORD heapSize, LPSTR cmdLine)
  53. {
  54.     SOM_IgnoreWarning (inst);
  55.     SOM_IgnoreWarning (ds);
  56.     SOM_IgnoreWarning (heapSize);
  57.     SOM_IgnoreWarning (cmdLine);
  58.  
  59.     SOM_ClassLibrary ("foo.dll");
  60.     return 1;
  61. }
  62. #endif
  63.