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.

137 lines
3.5 KiB

  1. // ResApi.idl : IDL source for Cluster Resource API
  2. //
  3. // This file will be processed by the MIDL tool to
  4. // produce the type library (resapi.tlb) and marshalling code.
  5. import "basetsd.h";
  6. import "oaidl.idl";
  7. import "wtypes.idl" ;
  8. ///////////////////////////////////////
  9. // definitions
  10. interface IClusterResControl ;
  11. interface IClusterResource ;
  12. interface IClusterQuorumResource ;
  13. //
  14. ///////////////////////////////////////
  15. /////////////////////////////////////////////////
  16. // Cluster
  17. [
  18. object,
  19. uuid(E2C31D50-BC17-11d0-A431-00C04FD735A9),
  20. dual,
  21. helpstring("Cluster Resource API Interface"),
  22. hidden,
  23. pointer_default(unique)
  24. ]
  25. interface IClusterResource : IDispatch
  26. {
  27. /////////////////////////////////
  28. // Cluster Resource API
  29. typedef long * POLEQUORUM_RESOURCE_LOST ;
  30. typedef ULONG_PTR OLEHANDLE ;
  31. typedef OLEHANDLE * LPOLEHANDLE ;
  32. typedef ULONG_PTR OLERESOURCE_HANDLE ;
  33. typedef ULONG_PTR OLEHKEY ;
  34. typedef ULONG_PTR OLERESID ;
  35. HRESULT Open( [in] BSTR ResourceName, [in] OLEHKEY ResourceKey, [in] OLERESOURCE_HANDLE ResourceHandle, [out, retval] OLERESID *lpRet ) ;
  36. HRESULT Close( [in] OLERESID Resource) ;
  37. HRESULT Online( [in] OLERESID Resource, [in,out] LPOLEHANDLE EventHandle, [out, retval] long *lpRet ) ;
  38. HRESULT Offline( [in] OLERESID Resource, [out, retval] long *lpRet ) ;
  39. HRESULT IsAlive( [in] OLERESID Resource, [out, retval] long *lpRet ) ;
  40. HRESULT LooksAlive( [in] OLERESID Resource, [out, retval] long *lpRet ) ;
  41. HRESULT Terminate( [in] OLERESID Resource) ;
  42. } ;
  43. [
  44. object,
  45. uuid(C56292B2-DD10-11D0-8490-00A0C90C13F8),
  46. dual,
  47. helpstring("Cluster Control Interface"),
  48. hidden,
  49. pointer_default(unique)
  50. ]
  51. interface IClusterResControl : IDispatch
  52. {
  53. HRESULT ResourceControl( [in] OLERESID Resource,
  54. [in] long ControlCode,
  55. [in] VARIANT *InBuffer,
  56. [in, out] VARIANT *OutBuffer,
  57. [in, out] long * BytesReturned,
  58. [out, retval] long *lpRet);
  59. HRESULT ResourceTypeControl(
  60. [in] BSTR ResourceTypeName,
  61. [in] long ControlCode,
  62. [in] VARIANT *InBuffer,
  63. [in, out] VARIANT *OutBuffer,
  64. [in, out] long * BytesReturned,
  65. [out, retval] long *lpRet);
  66. };
  67. // Quorum Resource
  68. [
  69. object,
  70. uuid(645B5A82-BC6E-11d0-8F45-000000000000),
  71. dual,
  72. helpstring("Cluster Resource Quorum Interface"),
  73. hidden,
  74. pointer_default(unique)
  75. ]
  76. interface IClusterQuorumResource : IDispatch
  77. {
  78. HRESULT QuorumArbitrate ( [in] OLERESID Resource, [in] POLEQUORUM_RESOURCE_LOST LostQuorumResource, [out, retval] long *lpRet ) ;
  79. HRESULT QuorumRelease ( [in] OLERESID Resource, [out, retval] long *lpRet ) ;
  80. };
  81. /////////////////////////////////////////////////////////
  82. // ResApi
  83. [
  84. uuid(E2C31D51-BC17-11d0-A431-00C04FD735A9),
  85. version(1.0),
  86. helpstring("MS Cluster Resource API 1.0 Type Library")
  87. ]
  88. library ResApi
  89. {
  90. importlib("stdole2.tlb");
  91. [
  92. uuid(688D8212-DD11-11D0-8490-00A0C90C13F8),
  93. helpstring("Cluster Control interface")
  94. ]
  95. coclass ClusterResControl
  96. {
  97. [default] interface IClusterResControl ;
  98. } ;
  99. [
  100. uuid(4B2E1D3C-DAC6-11D0-848C-00A0C90C13F8),
  101. helpstring("Cluster Quorum Resource API Class")
  102. ]
  103. coclass ClusterQuorumResource
  104. {
  105. [default] interface IClusterQuorumResource ;
  106. };
  107. [
  108. uuid(E2C31D52-BC17-11d0-A431-00C04FD735A9),
  109. helpstring("Cluster Resource API Class")
  110. ]
  111. coclass ClusterResource
  112. {
  113. [default] interface IClusterResource;
  114. };
  115. };