Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

149 lines
4.2 KiB

  1. //+-------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. // Copyright (C) Microsoft Corporation, 1992 - 1996.
  5. //
  6. // File: odeath.idl
  7. //
  8. //+-------------------------------------------------------------------------
  9. #ifndef DO_NO_IMPORTS
  10. import "unknwn.idl";
  11. import "obase.idl";
  12. import "wtypes.idl";
  13. import "objidl.idl";
  14. import "objidl.idl";
  15. #endif
  16. //+-------------------------------------------------------------------------
  17. //
  18. // Struct: XAptCallback
  19. //
  20. // Synopsys: An object context's DoCallback method must switch to its
  21. // apartment if it resides in a different apartment than the
  22. // caller. The context calls its apartment's remote unknown
  23. // to accomplish the switch. This structure is a parameter
  24. // block the object context passes to the remote unknown's
  25. // DoCallback method.
  26. //
  27. //--------------------------------------------------------------------------
  28. typedef __int64 PTRMEM;
  29. typedef struct tagXAptCallback
  30. {
  31. PTRMEM pfnCallback;
  32. PTRMEM pParam;
  33. PTRMEM pServerCtx;
  34. PTRMEM pUnk;
  35. GUID iid;
  36. int iMethod;
  37. } XAptCallback;
  38. //+-------------------------------------------------------------------------
  39. //
  40. // Interface: IRemUnknownN
  41. //
  42. // Synopsys: This is a local interface used to convert strong references
  43. // to weak references and vice versa. It is needed for the
  44. // container/link/embedding aspects of OLE.
  45. //
  46. // It inherits from the highest numbered IRemUnknown version
  47. // that is known for the current machine.
  48. //
  49. // Notes: Weak references are not permitted remotely.
  50. //
  51. //+-------------------------------------------------------------------------
  52. [
  53. object,
  54. uuid(0000013C-0000-0000-C000-000000000046)
  55. ]
  56. interface IRemUnknownN : IRemUnknown2
  57. {
  58. #ifndef DO_NO_IMPORTS
  59. import "remunk.idl";
  60. #endif
  61. const unsigned long IRUF_CONVERTTOWEAK = 0x01;// make refs weak
  62. const unsigned long IRUF_CONVERTTOSTRONG = 0x02;// make refs strong
  63. const unsigned long IRUF_DISCONNECTIFLASTSTRONG = 0x04;// disconnect the
  64. // object if last strong ref
  65. HRESULT RemChangeRef
  66. (
  67. [in] unsigned long flags,
  68. [in] unsigned short cInterfaceRefs,
  69. [in, size_is(cInterfaceRefs)] REMINTERFACEREF InterfaceRefs[]
  70. );
  71. HRESULT DoCallback
  72. (
  73. [in] XAptCallback *pCallbackData
  74. );
  75. }
  76. //
  77. // Enumeration to describe status of trying to run an oid down
  78. //
  79. typedef enum
  80. {
  81. ORS_DONTRUNDOWN = 0x0, // rundown refused
  82. ORS_OK_TO_RUNDOWN = 0x1, // rundown accepted
  83. ORS_OID_PINNED = 0x2 // rundown refused because stub is locked
  84. } OID_RUNDOWN_STATUS;
  85. //+-------------------------------------------------------------------------
  86. //
  87. // Interface: IRundown
  88. //
  89. // Synopsys: This is the local OID rundown interface. The object exporter
  90. // calls it to notify the server which OIDs are no longer being
  91. // pinged.
  92. //
  93. // Notes: This inherits from IRemUnknownN so that we can use the same
  94. // IPID for all three interfaces. This is strictly a local
  95. // implementation decision and does not affect remote protocol.
  96. //
  97. //+-------------------------------------------------------------------------
  98. [
  99. uuid(00000134-0000-0000-C000-000000000046)
  100. #ifndef RAW
  101. , object
  102. #endif
  103. ]
  104. interface IRundown
  105. #ifndef RAW
  106. : IRemUnknownN
  107. #endif
  108. {
  109. #ifndef DO_NO_IMPORTS
  110. import "iface.idl";
  111. import "obase.idl";
  112. import "remunk.idl";
  113. #endif
  114. #include "comhndl.h"
  115. COM_DEFINES(IOSCM)
  116. #ifdef RAW
  117. // Define the functions in IRemUnknown2
  118. HRESULT DummyRemQuery( handle_t handle );
  119. HRESULT DummyRemAddRef( handle_t handle );
  120. HRESULT DummyRemRelease( handle_t handle );
  121. HRESULT DummyRemChangeRef( handle_t handle );
  122. HRESULT DummyRemQueryInterface2( handle_t handle);
  123. HRESULT DummyDoCallBack( handle_t handle);
  124. error_status_t RawRundownOid
  125. #else
  126. HRESULT RundownOid
  127. #endif
  128. (
  129. COM_HANDLE
  130. [in] ULONG cOid,
  131. [in, size_is(cOid)] OID aOid[],
  132. [out, size_is(cOid)] BYTE aRundownStatus[] // see OID_RUNDOWN_STATUS above
  133. );
  134. }