138 lines
3.5 KiB
Plaintext
138 lines
3.5 KiB
Plaintext
// ResApi.idl : IDL source for Cluster Resource API
|
|
//
|
|
|
|
// This file will be processed by the MIDL tool to
|
|
// produce the type library (resapi.tlb) and marshalling code.
|
|
|
|
|
|
import "basetsd.h";
|
|
import "oaidl.idl";
|
|
import "wtypes.idl" ;
|
|
|
|
///////////////////////////////////////
|
|
// definitions
|
|
interface IClusterResControl ;
|
|
interface IClusterResource ;
|
|
interface IClusterQuorumResource ;
|
|
//
|
|
///////////////////////////////////////
|
|
|
|
/////////////////////////////////////////////////
|
|
// Cluster
|
|
[
|
|
object,
|
|
uuid(E2C31D50-BC17-11d0-A431-00C04FD735A9),
|
|
dual,
|
|
helpstring("Cluster Resource API Interface"),
|
|
hidden,
|
|
pointer_default(unique)
|
|
]
|
|
interface IClusterResource : IDispatch
|
|
{
|
|
/////////////////////////////////
|
|
// Cluster Resource API
|
|
|
|
typedef long * POLEQUORUM_RESOURCE_LOST ;
|
|
typedef ULONG_PTR OLEHANDLE ;
|
|
typedef OLEHANDLE * LPOLEHANDLE ;
|
|
typedef ULONG_PTR OLERESOURCE_HANDLE ;
|
|
typedef ULONG_PTR OLEHKEY ;
|
|
typedef ULONG_PTR OLERESID ;
|
|
|
|
|
|
HRESULT Open( [in] BSTR ResourceName, [in] OLEHKEY ResourceKey, [in] OLERESOURCE_HANDLE ResourceHandle, [out, retval] OLERESID *lpRet ) ;
|
|
HRESULT Close( [in] OLERESID Resource) ;
|
|
|
|
HRESULT Online( [in] OLERESID Resource, [in,out] LPOLEHANDLE EventHandle, [out, retval] long *lpRet ) ;
|
|
HRESULT Offline( [in] OLERESID Resource, [out, retval] long *lpRet ) ;
|
|
|
|
HRESULT IsAlive( [in] OLERESID Resource, [out, retval] long *lpRet ) ;
|
|
HRESULT LooksAlive( [in] OLERESID Resource, [out, retval] long *lpRet ) ;
|
|
|
|
HRESULT Terminate( [in] OLERESID Resource) ;
|
|
|
|
} ;
|
|
|
|
[
|
|
object,
|
|
uuid(C56292B2-DD10-11D0-8490-00A0C90C13F8),
|
|
dual,
|
|
helpstring("Cluster Control Interface"),
|
|
hidden,
|
|
pointer_default(unique)
|
|
]
|
|
interface IClusterResControl : IDispatch
|
|
{
|
|
HRESULT ResourceControl( [in] OLERESID Resource,
|
|
[in] long ControlCode,
|
|
[in] VARIANT *InBuffer,
|
|
[in, out] VARIANT *OutBuffer,
|
|
[in, out] long * BytesReturned,
|
|
[out, retval] long *lpRet);
|
|
|
|
HRESULT ResourceTypeControl(
|
|
[in] BSTR ResourceTypeName,
|
|
[in] long ControlCode,
|
|
[in] VARIANT *InBuffer,
|
|
[in, out] VARIANT *OutBuffer,
|
|
[in, out] long * BytesReturned,
|
|
[out, retval] long *lpRet);
|
|
};
|
|
|
|
// Quorum Resource
|
|
|
|
[
|
|
object,
|
|
uuid(645B5A82-BC6E-11d0-8F45-000000000000),
|
|
dual,
|
|
helpstring("Cluster Resource Quorum Interface"),
|
|
hidden,
|
|
pointer_default(unique)
|
|
]
|
|
interface IClusterQuorumResource : IDispatch
|
|
{
|
|
HRESULT QuorumArbitrate ( [in] OLERESID Resource, [in] POLEQUORUM_RESOURCE_LOST LostQuorumResource, [out, retval] long *lpRet ) ;
|
|
HRESULT QuorumRelease ( [in] OLERESID Resource, [out, retval] long *lpRet ) ;
|
|
};
|
|
|
|
|
|
/////////////////////////////////////////////////////////
|
|
// ResApi
|
|
[
|
|
uuid(E2C31D51-BC17-11d0-A431-00C04FD735A9),
|
|
version(1.0),
|
|
helpstring("MS Cluster Resource API 1.0 Type Library")
|
|
]
|
|
library ResApi
|
|
{
|
|
importlib("stdole2.tlb");
|
|
|
|
[
|
|
uuid(688D8212-DD11-11D0-8490-00A0C90C13F8),
|
|
helpstring("Cluster Control interface")
|
|
]
|
|
coclass ClusterResControl
|
|
{
|
|
[default] interface IClusterResControl ;
|
|
} ;
|
|
|
|
[
|
|
uuid(4B2E1D3C-DAC6-11D0-848C-00A0C90C13F8),
|
|
helpstring("Cluster Quorum Resource API Class")
|
|
]
|
|
coclass ClusterQuorumResource
|
|
{
|
|
[default] interface IClusterQuorumResource ;
|
|
};
|
|
|
|
[
|
|
uuid(E2C31D52-BC17-11d0-A431-00C04FD735A9),
|
|
helpstring("Cluster Resource API Class")
|
|
]
|
|
coclass ClusterResource
|
|
{
|
|
[default] interface IClusterResource;
|
|
};
|
|
|
|
};
|