⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 opccomn.idl

📁 Visual C++通信编程工程实例精解(附盘)
💻 IDL
字号:
// OPCCOMN.IDL
// REVISION:  04/06/98 08:00 PM (EST)
// VERSIONINFO	1.0.0.0
// 
// 04/09/98 acc import unknwn.idl rather than oaidl.idl
// 06/15/98 acc add 'library' object at end to allow typelib generation
// 06/19/98 acc change V2 uuids prior to final release
//              to avoid conflict with 'old' OPCDA Automation uuids
// 09/18/98 acc add OPCServerList IDL (with help from Gary Klassen)
//
     
import "unknwn.idl";
import "comcat.idl";


//****************************************************
// All servers except OPCDA1.0 have the ability to 
// make callbacks into the client on shutdown via
// IOPCShutdown 
//****************************************************
[
  object,
  uuid(F31DFDE1-07B6-11d2-B2D8-0060083BA1FB),
  pointer_default(unique)
]
interface IOPCShutdown : IUnknown
{
  HRESULT ShutdownRequest (
    [in, string] LPCWSTR szReason
    );
}

//****************************************************
// All servers except OPCDA1.0 support IOPCCommon
//****************************************************
[
  object,
  uuid(F31DFDE2-07B6-11d2-B2D8-0060083BA1FB),
  pointer_default(unique)
]
interface IOPCCommon : IUnknown
{

  HRESULT SetLocaleID ( 
    [in] LCID dwLcid
    );

  HRESULT GetLocaleID ( 
    [out] LCID *pdwLcid
    );

  HRESULT QueryAvailableLocaleIDs ( 
    [out] DWORD *pdwCount,
    [out, size_is(,*pdwCount)] LCID **pdwLcid
    );

  HRESULT GetErrorString( 
    [in] HRESULT dwError,
    [out, string] LPWSTR *ppString
    );

  HRESULT SetClientName ( 
    [in, string] LPCWSTR szName 
    );

}


//****************************************************
// The OPCEnum.EXE object provided by the OPC Foundation
// supports the IOPCServerList interface via DCOM
// to allow clients to determine available OPC servers
// on remote machines
//****************************************************

[
	object,
	uuid(13486D50-4821-11D2-A494-3CB306C10000),
	pointer_default(unique)
]
interface IOPCServerList : IUnknown
{
	HRESULT EnumClassesOfCategories(
		[in] ULONG cImplemented,
		[in,size_is(cImplemented)] CATID rgcatidImpl[],
		[in] ULONG cRequired,
		[in,size_is(cRequired)] CATID rgcatidReq[],
		[out] IEnumGUID** ppenumClsid);

	HRESULT GetClassDetails(
		[in] REFCLSID clsid, 
		[out] LPOLESTR* ppszProgID, 
		[out] LPOLESTR* ppszUserType);

	HRESULT CLSIDFromProgID(
		[in] LPCOLESTR szProgId, 
		[out] LPCLSID clsid);
};



//****************************************************
// This TYPELIB is generated as a convenience to users of high level tools
// which are capable of using or browsing TYPELIBs. 
// 'Smart Pointers' in VC5 is one example.
//****************************************************
[
    uuid(B28EEDB1-AC6F-11d1-84D5-00608CB8A7E9),
    version(1.0),
    helpstring("OPCCOMN 1.0 Type Library")
]
library OPCCOMN
{
    importlib("stdole32.tlb");
    importlib("stdole2.tlb");

    interface IOPCCommon;
    interface IOPCShutdown;
	interface IOpcServerList;
};


⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -