📄 opc_ae_ps.cpp
字号:
/* opc_ae_ps.cpp generated by WIDL Version 2.2.1 on 06-Dec-01 at 11:55:11 AM */#define __WIDL_PROXY_STUB 0x0200#include "dcomProxy.h"#include "opc_ae.h"#include <string.h>extern "C" int include_opc_ae () {return 0;}NdrTypeDesc StructDesc__FILETIME(NDRTYPES&);NdrTypeDesc StructDesc__FILETIME(NDRTYPES&);NdrTypeDesc StructDesc_tagVARIANT(NDRTYPES&);NdrTypeDesc StructDesc_tagONEVENTSTRUCT (NDRTYPES& ndrtypes) { NdrMemberInfo m [] = { NDR_MEMBER(tagONEVENTSTRUCT, wChangeMask, ndrtypes.short_t ()), NDR_MEMBER(tagONEVENTSTRUCT, wNewState, ndrtypes.short_t ()), NDR_MEMBER(tagONEVENTSTRUCT, szSource, ndrtypes.pointer_t(ndrtypes.wstring_t ())), NDR_MEMBER(tagONEVENTSTRUCT, ftTime, StructDesc__FILETIME (ndrtypes)), NDR_MEMBER(tagONEVENTSTRUCT, szMessage, ndrtypes.pointer_t(ndrtypes.wstring_t ())), NDR_MEMBER(tagONEVENTSTRUCT, dwEventType, ndrtypes.ulong_t ()), NDR_MEMBER(tagONEVENTSTRUCT, dwEventCategory, ndrtypes.ulong_t ()), NDR_MEMBER(tagONEVENTSTRUCT, dwSeverity, ndrtypes.ulong_t ()), NDR_MEMBER(tagONEVENTSTRUCT, szConditionName, ndrtypes.pointer_t(ndrtypes.wstring_t ())), NDR_MEMBER(tagONEVENTSTRUCT, szSubconditionName, ndrtypes.pointer_t(ndrtypes.wstring_t ())), NDR_MEMBER(tagONEVENTSTRUCT, wQuality, ndrtypes.short_t ()), NDR_MEMBER(tagONEVENTSTRUCT, wReserved, ndrtypes.short_t ()), NDR_MEMBER(tagONEVENTSTRUCT, bAckRequired, ndrtypes.int_t ()), NDR_MEMBER(tagONEVENTSTRUCT, ftActiveTime, StructDesc__FILETIME (ndrtypes)), NDR_MEMBER(tagONEVENTSTRUCT, dwCookie, ndrtypes.ulong_t ()), NDR_MEMBER(tagONEVENTSTRUCT, dwNumEventAttrs, ndrtypes.ulong_t ()), NDR_MEMBERX(tagONEVENTSTRUCT, pEventAttributes, ndrtypes.pointer_t(ndrtypes.carray_t(ndrtypes.variant_t (), NDR_SIZEOF(VARIANT))), 15), NDR_MEMBER(tagONEVENTSTRUCT, szActorID, ndrtypes.pointer_t(ndrtypes.wstring_t ())), }; return ndrtypes.struct_t (18, m, 15); }NdrTypeDesc StructDesc__FILETIME(NDRTYPES&);NdrTypeDesc StructDesc__FILETIME(NDRTYPES&);NdrTypeDesc StructDesc__FILETIME(NDRTYPES&);NdrTypeDesc StructDesc_tagOPCEVENTSERVERSTATUS (NDRTYPES& ndrtypes) { NdrMemberInfo m [] = { NDR_MEMBER(tagOPCEVENTSERVERSTATUS, ftStartTime, StructDesc__FILETIME (ndrtypes)), NDR_MEMBER(tagOPCEVENTSERVERSTATUS, ftCurrentTime, StructDesc__FILETIME (ndrtypes)), NDR_MEMBER(tagOPCEVENTSERVERSTATUS, ftLastUpdateTime, StructDesc__FILETIME (ndrtypes)), NDR_MEMBER(tagOPCEVENTSERVERSTATUS, dwServerState, ndrtypes.enum_t ()), NDR_MEMBER(tagOPCEVENTSERVERSTATUS, wMajorVersion, ndrtypes.short_t ()), NDR_MEMBER(tagOPCEVENTSERVERSTATUS, wMinorVersion, ndrtypes.short_t ()), NDR_MEMBER(tagOPCEVENTSERVERSTATUS, wBuildNumber, ndrtypes.short_t ()), NDR_MEMBER(tagOPCEVENTSERVERSTATUS, wReserved, ndrtypes.short_t ()), NDR_MEMBER(tagOPCEVENTSERVERSTATUS, szVendorInfo, ndrtypes.pointer_t(ndrtypes.wstring_t ())), }; return ndrtypes.struct_t (9, m); }NdrTypeDesc StructDesc__FILETIME(NDRTYPES&);NdrTypeDesc StructDesc__FILETIME(NDRTYPES&);NdrTypeDesc StructDesc__FILETIME(NDRTYPES&);NdrTypeDesc StructDesc__FILETIME(NDRTYPES&);NdrTypeDesc StructDesc_tagVARIANT(NDRTYPES&);NdrTypeDesc StructDesc_tagOPCCONDITIONSTATE (NDRTYPES& ndrtypes) { NdrMemberInfo m [] = { NDR_MEMBER(tagOPCCONDITIONSTATE, wState, ndrtypes.short_t ()), NDR_MEMBER(tagOPCCONDITIONSTATE, wReserved1, ndrtypes.short_t ()), NDR_MEMBER(tagOPCCONDITIONSTATE, szActiveSubCondition, ndrtypes.pointer_t(ndrtypes.wstring_t ())), NDR_MEMBER(tagOPCCONDITIONSTATE, szASCDefinition, ndrtypes.pointer_t(ndrtypes.wstring_t ())), NDR_MEMBER(tagOPCCONDITIONSTATE, dwASCSeverity, ndrtypes.ulong_t ()), NDR_MEMBER(tagOPCCONDITIONSTATE, szASCDescription, ndrtypes.pointer_t(ndrtypes.wstring_t ())), NDR_MEMBER(tagOPCCONDITIONSTATE, wQuality, ndrtypes.short_t ()), NDR_MEMBER(tagOPCCONDITIONSTATE, wReserved2, ndrtypes.short_t ()), NDR_MEMBER(tagOPCCONDITIONSTATE, ftLastAckTime, StructDesc__FILETIME (ndrtypes)), NDR_MEMBER(tagOPCCONDITIONSTATE, ftSubCondLastActive, StructDesc__FILETIME (ndrtypes)), NDR_MEMBER(tagOPCCONDITIONSTATE, ftCondLastActive, StructDesc__FILETIME (ndrtypes)), NDR_MEMBER(tagOPCCONDITIONSTATE, ftCondLastInactive, StructDesc__FILETIME (ndrtypes)), NDR_MEMBER(tagOPCCONDITIONSTATE, szAcknowledgerID, ndrtypes.pointer_t(ndrtypes.wstring_t ())), NDR_MEMBER(tagOPCCONDITIONSTATE, szComment, ndrtypes.pointer_t(ndrtypes.wstring_t ())), NDR_MEMBER(tagOPCCONDITIONSTATE, dwNumSCs, ndrtypes.ulong_t ()), NDR_MEMBERX(tagOPCCONDITIONSTATE, pszSCNames, ndrtypes.pointer_t(ndrtypes.carray_t(ndrtypes.pointer_t(ndrtypes.wstring_t ()), NDR_SIZEOF(LPWSTR))), 14), NDR_MEMBERX(tagOPCCONDITIONSTATE, pszSCDefinitions, ndrtypes.pointer_t(ndrtypes.carray_t(ndrtypes.pointer_t(ndrtypes.wstring_t ()), NDR_SIZEOF(LPWSTR))), 14), NDR_MEMBERX(tagOPCCONDITIONSTATE, pdwSCSeverities, ndrtypes.pointer_t(ndrtypes.carray_t(ndrtypes.ulong_t (), NDR_SIZEOF(DWORD))), 14), NDR_MEMBERX(tagOPCCONDITIONSTATE, pszSCDescriptions, ndrtypes.pointer_t(ndrtypes.carray_t(ndrtypes.pointer_t(ndrtypes.wstring_t ()), NDR_SIZEOF(LPWSTR))), 14), NDR_MEMBER(tagOPCCONDITIONSTATE, dwNumEventAttrs, ndrtypes.ulong_t ()), NDR_MEMBERX(tagOPCCONDITIONSTATE, pEventAttributes, ndrtypes.pointer_t(ndrtypes.carray_t(ndrtypes.variant_t (), NDR_SIZEOF(VARIANT))), 19), NDR_MEMBERX(tagOPCCONDITIONSTATE, pErrors, ndrtypes.pointer_t(ndrtypes.carray_t(ndrtypes.long_t (), NDR_SIZEOF(HRESULT))), 19), }; return ndrtypes.struct_t (22, m, 19); }NdrTypeDesc StructDesc_tagOPCEVENTSERVERSTATUS(NDRTYPES&);NdrTypeDesc StructDesc__GUID(NDRTYPES&);NdrTypeDesc StructDesc__GUID(NDRTYPES&);NdrTypeDesc StructDesc_tagOPCCONDITIONSTATE(NDRTYPES&);NdrTypeDesc StructDesc__FILETIME(NDRTYPES&);NdrTypeDesc StructDesc__GUID(NDRTYPES&);NdrTypeDesc StructDesc_tagONEVENTSTRUCT(NDRTYPES&);HRESULT STDMETHODCALLTYPE IOPCEventServer_GetStatus_vxproxy (IOPCEventServer* pThis, OPCEVENTSERVERSTATUS** ppEventServerStatus) { RPC_PROXY_MSG msg (IID_IOPCEventServer, RpcMode::OBJECT, 3, pThis); NDRTYPES ndrtypes; HRESULT hrMethod; HRESULT hr; hr = msg.SendReceive (); if (FAILED (hr)) return hr; NdrUnmarshalStream* pus = msg.unmarshalStreamGet (); hr=widlUnmarshal (&ppEventServerStatus, pus, ndrtypes.refptr_t(ndrtypes.pointer_t(StructDesc_tagOPCEVENTSERVERSTATUS (ndrtypes)))); if (FAILED(hr)) return hr; hr = widlUnmarshal (&hrMethod, pus, ndrtypes.hresult_t()); if (FAILED(hr)) return hr; return hrMethod; }HRESULT STDMETHODCALLTYPE IOPCEventServer_GetStatus_vxstub (IOPCEventServer* pitf, RPC_STUB_MSG& msg) { NDRTYPES ndrtypes; HRESULT hr; HRESULT hrMethod; OPCEVENTSERVERSTATUS* ppEventServerStatus_tmp; OPCEVENTSERVERSTATUS** ppEventServerStatus = &ppEventServerStatus_tmp; hrMethod = pitf->GetStatus (ppEventServerStatus); NdrMarshalStream* pms = msg.marshalStreamGet (); hr=widlMarshal (&ppEventServerStatus, pms, ndrtypes.refptr_t(ndrtypes.pointer_t(StructDesc_tagOPCEVENTSERVERSTATUS (ndrtypes)))); if (FAILED(hr)) return hr; hr = widlMarshal (&hrMethod, pms, ndrtypes.hresult_t()); if (FAILED(hr)) return hr; if ((*ppEventServerStatus)) {if ((*(*ppEventServerStatus)).szVendorInfo) {CoTaskMemFree ((*(*ppEventServerStatus)).szVendorInfo);}CoTaskMemFree ((*ppEventServerStatus));}; return S_OK; }HRESULT STDMETHODCALLTYPE IOPCEventServer_CreateEventSubscription_vxproxy (IOPCEventServer* pThis, BOOL bActive, DWORD dwBufferTime, DWORD dwMaxSize, OPCHANDLE hClientSubscription, REFIID riid, LPUNKNOWN* ppUnk, DWORD* pdwRevisedBufferTime, DWORD* pdwRevisedMaxSize) { RPC_PROXY_MSG msg (IID_IOPCEventServer, RpcMode::OBJECT, 4, pThis); NDRTYPES ndrtypes; HRESULT hrMethod; HRESULT hr; NdrMarshalStream* pms = msg.marshalStreamGet (); hr=widlMarshal (&bActive, pms, ndrtypes.int_t ()); if (FAILED(hr)) return hr; hr=widlMarshal (&dwBufferTime, pms, ndrtypes.ulong_t ()); if (FAILED(hr)) return hr; hr=widlMarshal (&dwMaxSize, pms, ndrtypes.ulong_t ()); if (FAILED(hr)) return hr; hr=widlMarshal (&hClientSubscription, pms, ndrtypes.ulong_t ()); if (FAILED(hr)) return hr; hr=widlMarshal (&riid, pms, StructDesc__GUID (ndrtypes)); if (FAILED(hr)) return hr; hr = msg.SendReceive (); if (FAILED (hr)) return hr; NdrUnmarshalStream* pus = msg.unmarshalStreamGet (); hr=widlUnmarshal (&ppUnk, pus, ndrtypes.refptr_t(ndrtypes.interfaceptr_t (IID_IUnknown))); if (FAILED(hr)) return hr; hr=widlUnmarshal (&pdwRevisedBufferTime, pus, ndrtypes.refptr_t(ndrtypes.ulong_t ())); if (FAILED(hr)) return hr; hr=widlUnmarshal (&pdwRevisedMaxSize, pus, ndrtypes.refptr_t(ndrtypes.ulong_t ())); if (FAILED(hr)) return hr; hr = widlUnmarshal (&hrMethod, pus, ndrtypes.hresult_t()); if (FAILED(hr)) return hr; return hrMethod; }HRESULT STDMETHODCALLTYPE IOPCEventServer_CreateEventSubscription_vxstub (IOPCEventServer* pitf, RPC_STUB_MSG& msg) { NDRTYPES ndrtypes; HRESULT hr; HRESULT hrMethod; NdrUnmarshalStream* pus = msg.unmarshalStreamGet (); BOOL bActive; hr=widlUnmarshal (&bActive, pus, ndrtypes.int_t ()); if (FAILED(hr)) return hr; DWORD dwBufferTime; hr=widlUnmarshal (&dwBufferTime, pus, ndrtypes.ulong_t ()); if (FAILED(hr)) return hr; DWORD dwMaxSize; hr=widlUnmarshal (&dwMaxSize, pus, ndrtypes.ulong_t ()); if (FAILED(hr)) return hr; OPCHANDLE hClientSubscription; hr=widlUnmarshal (&hClientSubscription, pus, ndrtypes.ulong_t ()); if (FAILED(hr)) return hr; IID riid; hr=widlUnmarshal (&riid, pus, StructDesc__GUID (ndrtypes)); if (FAILED(hr)) return hr; LPUNKNOWN ppUnk_tmp; LPUNKNOWN* ppUnk = &ppUnk_tmp; DWORD pdwRevisedBufferTime_tmp; DWORD* pdwRevisedBufferTime = &pdwRevisedBufferTime_tmp; DWORD pdwRevisedMaxSize_tmp; DWORD* pdwRevisedMaxSize = &pdwRevisedMaxSize_tmp; hrMethod = pitf->CreateEventSubscription (bActive, dwBufferTime, dwMaxSize, hClientSubscription, riid, ppUnk, pdwRevisedBufferTime, pdwRevisedMaxSize); NdrMarshalStream* pms = msg.marshalStreamGet (); hr=widlMarshal (&ppUnk, pms, ndrtypes.refptr_t(ndrtypes.interfaceptr_t (IID_IUnknown))); if (FAILED(hr)) return hr; hr=widlMarshal (&pdwRevisedBufferTime, pms, ndrtypes.refptr_t(ndrtypes.ulong_t ())); if (FAILED(hr)) return hr; hr=widlMarshal (&pdwRevisedMaxSize, pms, ndrtypes.refptr_t(ndrtypes.ulong_t ())); if (FAILED(hr)) return hr; hr = widlMarshal (&hrMethod, pms, ndrtypes.hresult_t()); if (FAILED(hr)) return hr; if ((*ppUnk)) {((*ppUnk))->Release ();}; return S_OK; }HRESULT STDMETHODCALLTYPE IOPCEventServer_QueryAvailableFilters_vxproxy (IOPCEventServer* pThis, DWORD* pdwFilterMask) { RPC_PROXY_MSG msg (IID_IOPCEventServer, RpcMode::OBJECT, 5, pThis); NDRTYPES ndrtypes; HRESULT hrMethod; HRESULT hr; hr = msg.SendReceive (); if (FAILED (hr)) return hr; NdrUnmarshalStream* pus = msg.unmarshalStreamGet (); hr=widlUnmarshal (&pdwFilterMask, pus, ndrtypes.refptr_t(ndrtypes.ulong_t ())); if (FAILED(hr)) return hr; hr = widlUnmarshal (&hrMethod, pus, ndrtypes.hresult_t()); if (FAILED(hr)) return hr; return hrMethod; }HRESULT STDMETHODCALLTYPE IOPCEventServer_QueryAvailableFilters_vxstub (IOPCEventServer* pitf, RPC_STUB_MSG& msg) { NDRTYPES ndrtypes; HRESULT hr; HRESULT hrMethod; DWORD pdwFilterMask_tmp; DWORD* pdwFilterMask = &pdwFilterMask_tmp;
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -