home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / odtlktv4.zip / ODTLKT / TOOLKIT / IDL / COMPMGR.IDL < prev    next >
Text File  |  1995-12-13  |  4KB  |  122 lines

  1. /********************************************************************/
  2. /*  Licensed Materials - Property of IBM                            */
  3. /*                                                                  */
  4. /*                                                                  */
  5. /* Copyright (C) International Business Machines Corp., 1994.       */
  6. /* Copyright (C) Apple Computer, Inc., 1994                         */
  7. /*                                                                  */
  8. /*  US Government Users Restricted Rights -                         */
  9. /*  Use, duplication, or disclosure restricted                      */
  10. /*  by GSA ADP Schedule Contract with IBM Corp.                     */
  11. /*                                                                  */
  12. /*                                                                  */
  13. /********************************************************************/
  14.  
  15. #ifndef _COMPONENT_
  16. #include <comp.idl>
  17. #endif
  18.  
  19. #ifndef _COMPONENTMANAGER_
  20. #define _COMPONENTMANAGER_
  21.  
  22. //==============================================================================
  23. // Classes defined in this interface
  24. //==============================================================================
  25.  
  26. interface ComponentManager;
  27. interface M_ComponentManager;
  28.  
  29. //==============================================================================
  30. // Classes used by this interface
  31. //==============================================================================
  32.  
  33. interface Component;
  34.  
  35. //==============================================================================
  36. // Implementation Types
  37. //==============================================================================
  38.  
  39. //==============================================================================
  40. // Class ComponentManager
  41. //==============================================================================
  42.  
  43. interface M_ComponentManager : SOMClass {
  44.  
  45. #ifdef __SOMIDL__
  46.  
  47.  
  48. implementation {
  49.  
  50.         Environment    ev;
  51.  
  52.         majorversion = 1;
  53.         minorversion = 0;
  54.         functionprefix = M_CMGR_;
  55.         releaseorder : Reserved1;
  56.         somDefaultInit: override, init;
  57.         somDestruct: override;
  58.         dllname = "OPENDOC.DLL";
  59. };
  60.  
  61. #endif
  62.  
  63. };
  64.  
  65. interface ComponentManager : SOMObject {
  66.  
  67. ODULong               CountComponents(in ComponentDescription *plooking);
  68.  
  69. OSErr                 FindNextComponent(in ComponentDescription *plastFound,
  70.                                         in ComponentDescription *plooking,
  71.                                         out ComponentDescription pfound);
  72.  
  73. OSErr                 GetComponentInfo(in ComponentDescription *ptheComponent,
  74.                                        out char pcomponentName,
  75.                                        out char pcomponentInfo);
  76.  
  77. ODSLong               GetComponentRefcon(in ComponentDescription *ptheComponent);
  78.  
  79. void                  SetComponentRefcon(in ComponentDescription *ptheComponent,
  80.                                          in ODSLong Refcon);
  81.  
  82. Component             OpenComponent(in ComponentDescription *ptheComponent);
  83.  
  84. Component             OpenDefaultComponent(in OSType componentType,
  85.                                            in OSType componentSubType);
  86.  
  87. OSErr                 CloseComponent(in Component theComponentInstance);
  88.  
  89. OSErr                 InstallComponent(in ComponentRegistryData *ptheData);
  90.  
  91. OSErr                 UninstallComponent(in OSType componentType,
  92.                                          in OSType componentSubType);
  93.  
  94. #ifdef __SOMIDL__
  95.  
  96. implementation
  97. {
  98.  
  99.         majorversion = 1;
  100.         minorversion = 0;
  101.         metaclass = M_ComponentManager;
  102.         functionprefix = CMGR_;
  103.         releaseorder :  CountComponents,
  104.                         FindNextComponent,
  105.                         GetComponentInfo,
  106.                         GetComponentRefcon,
  107.                         SetComponentRefcon,
  108.                         OpenComponent,
  109.                         OpenDefaultComponent,
  110.                         CloseComponent,
  111.                         InstallComponent,
  112.                         UninstallComponent;
  113.         somDefaultInit: override, init;
  114.         somDestruct: override;
  115.         dllname = "OPENDOC.DLL";
  116. };
  117.  
  118. #endif
  119.  
  120. };
  121. #endif
  122.