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.

237 lines
9.0 KiB

  1. /******************************************************************
  2. Copyright (c) 1999 Microsoft Corporation
  3. GotNet.H -- WMI provider class definition
  4. Generated by Microsoft WBEM Code Generation Engine
  5. Description:
  6. *******************************************************************/
  7. // Property set identification
  8. //============================
  9. #ifndef _GotNet_H_
  10. #define _GotNet_H_
  11. #define PROVIDER_NAME_GOTNET L"NetDiagnostics"
  12. // Property name externs -- defined in GotNet.cpp
  13. //=================================================
  14. extern const WCHAR* pbIEProxy ;
  15. extern const WCHAR* pbMailPop3Port ;
  16. extern const WCHAR* pbMailSMTPPort ;
  17. extern const WCHAR* pbNewsNNTPPort ;
  18. extern const WCHAR* pbPingGateway ;
  19. extern const WCHAR* pbPingIP ;
  20. extern const WCHAR* pbPingLoopback ;
  21. extern const WCHAR* pbPingMailServer ;
  22. extern const WCHAR* pbPingNewsServer ;
  23. extern const WCHAR* pid ;
  24. extern const WCHAR* pIEProxy ;
  25. extern const WCHAR* pMailServer ;
  26. extern const WCHAR* pNewsServer ;
  27. extern const WCHAR* pPingGateway ;
  28. extern const WCHAR* pPingIP ;
  29. extern const WCHAR* pPingLoopback ;
  30. extern const WCHAR* pPingMailServer ;
  31. extern const WCHAR* pPingNewsServer ;
  32. class CGotNet : public IWbemServices, public IWbemProviderInit
  33. {
  34. public:
  35. CGotNet();
  36. virtual ~CGotNet();
  37. protected:
  38. ULONG m_cRef; // Object reference count
  39. IWbemServices * m_pNamespace;
  40. public:
  41. //Non-delegating object IUnknown
  42. STDMETHODIMP QueryInterface(REFIID, LPVOID*);
  43. STDMETHODIMP_(ULONG) AddRef(void);
  44. STDMETHODIMP_(ULONG) Release(void);
  45. //IWbemProviderInit
  46. // -------------IMPLEMENT-------------------------------------------------
  47. HRESULT STDMETHODCALLTYPE Initialize(
  48. /* [in] */ LPWSTR pszUser,
  49. /* [in] */ LONG lFlags,
  50. /* [in] */ LPWSTR pszNamespace,
  51. /* [in] */ LPWSTR pszLocale,
  52. /* [in] */ IWbemServices *pNamespace,
  53. /* [in] */ IWbemContext *pCtx,
  54. /* [in] */ IWbemProviderInitSink *pInitSink);
  55. // -------------IMPLEMENT-------------------------------------------------
  56. SCODE GetByPath( BSTR Path, IWbemClassObject FAR* FAR* pObj, IWbemContext *pCtx);
  57. //IWbemServices
  58. // -------------IMPLEMENT-------------------------------------------------
  59. HRESULT STDMETHODCALLTYPE GetObjectAsync(
  60. /* [in] */ const BSTR ObjectPath,
  61. /* [in] */ long lFlags,
  62. /* [in] */ IWbemContext __RPC_FAR *pCtx,
  63. /* [in] */ IWbemObjectSink __RPC_FAR *pResponseHandler);
  64. // -------------IMPLEMENT-------------------------------------------------
  65. HRESULT STDMETHODCALLTYPE CreateInstanceEnumAsync(
  66. /* [in] */ const BSTR Class,
  67. /* [in] */ long lFlags,
  68. /* [in] */ IWbemContext __RPC_FAR *pCtx,
  69. /* [in] */ IWbemObjectSink __RPC_FAR *pResponseHandler);
  70. HRESULT STDMETHODCALLTYPE OpenNamespace(
  71. /* [in] */ const BSTR Namespace,
  72. /* [in] */ long lFlags,
  73. /* [in] */ IWbemContext __RPC_FAR *pCtx,
  74. /* [unique][in][out] */ IWbemServices __RPC_FAR *__RPC_FAR *ppWorkingNamespace,
  75. /* [unique][in][out] */ IWbemCallResult __RPC_FAR *__RPC_FAR *ppResult) {return WBEM_E_NOT_SUPPORTED;};
  76. HRESULT STDMETHODCALLTYPE CancelAsyncCall(
  77. /* [in] */ IWbemObjectSink __RPC_FAR *pSink) {return WBEM_E_NOT_SUPPORTED;};
  78. HRESULT STDMETHODCALLTYPE QueryObjectSink(
  79. /* [in] */ long lFlags,
  80. /* [out] */ IWbemObjectSink __RPC_FAR *__RPC_FAR *ppResponseHandler) {return WBEM_E_NOT_SUPPORTED;};
  81. HRESULT STDMETHODCALLTYPE GetObject(
  82. /* [in] */ const BSTR ObjectPath,
  83. /* [in] */ long lFlags,
  84. /* [in] */ IWbemContext __RPC_FAR *pCtx,
  85. /* [unique][in][out] */ IWbemClassObject __RPC_FAR *__RPC_FAR *ppObject,
  86. /* [unique][in][out] */ IWbemCallResult __RPC_FAR *__RPC_FAR *ppCallResult) {return WBEM_E_NOT_SUPPORTED;};
  87. HRESULT STDMETHODCALLTYPE PutClass(
  88. /* [in] */ IWbemClassObject __RPC_FAR *pObject,
  89. /* [in] */ long lFlags,
  90. /* [in] */ IWbemContext __RPC_FAR *pCtx,
  91. /* [unique][in][out] */ IWbemCallResult __RPC_FAR *__RPC_FAR *ppCallResult) {return WBEM_E_NOT_SUPPORTED;};
  92. HRESULT STDMETHODCALLTYPE PutClassAsync(
  93. /* [in] */ IWbemClassObject __RPC_FAR *pObject,
  94. /* [in] */ long lFlags,
  95. /* [in] */ IWbemContext __RPC_FAR *pCtx,
  96. /* [in] */ IWbemObjectSink __RPC_FAR *pResponseHandler) {return WBEM_E_NOT_SUPPORTED;};
  97. HRESULT STDMETHODCALLTYPE DeleteClass(
  98. /* [in] */ const BSTR Class,
  99. /* [in] */ long lFlags,
  100. /* [in] */ IWbemContext __RPC_FAR *pCtx,
  101. /* [unique][in][out] */ IWbemCallResult __RPC_FAR *__RPC_FAR *ppCallResult) {return WBEM_E_NOT_SUPPORTED;};
  102. HRESULT STDMETHODCALLTYPE DeleteClassAsync(
  103. /* [in] */ const BSTR Class,
  104. /* [in] */ long lFlags,
  105. /* [in] */ IWbemContext __RPC_FAR *pCtx,
  106. /* [in] */ IWbemObjectSink __RPC_FAR *pResponseHandler) {return WBEM_E_NOT_SUPPORTED;};
  107. HRESULT STDMETHODCALLTYPE CreateClassEnum(
  108. /* [in] */ const BSTR Superclass,
  109. /* [in] */ long lFlags,
  110. /* [in] */ IWbemContext __RPC_FAR *pCtx,
  111. /* [out] */ IEnumWbemClassObject __RPC_FAR *__RPC_FAR *ppEnum) {return WBEM_E_NOT_SUPPORTED;};
  112. HRESULT STDMETHODCALLTYPE CreateClassEnumAsync(
  113. /* [in] */ const BSTR Superclass,
  114. /* [in] */ long lFlags,
  115. /* [in] */ IWbemContext __RPC_FAR *pCtx,
  116. /* [in] */ IWbemObjectSink __RPC_FAR *pResponseHandler) {return WBEM_E_NOT_SUPPORTED;};
  117. HRESULT STDMETHODCALLTYPE PutInstance(
  118. /* [in] */ IWbemClassObject __RPC_FAR *pInst,
  119. /* [in] */ long lFlags,
  120. /* [in] */ IWbemContext __RPC_FAR *pCtx,
  121. /* [unique][in][out] */ IWbemCallResult __RPC_FAR *__RPC_FAR *ppCallResult) {return WBEM_E_NOT_SUPPORTED;};
  122. HRESULT STDMETHODCALLTYPE PutInstanceAsync(
  123. /* [in] */ IWbemClassObject __RPC_FAR *pInst,
  124. /* [in] */ long lFlags,
  125. /* [in] */ IWbemContext __RPC_FAR *pCtx,
  126. /* [in] */ IWbemObjectSink __RPC_FAR *pResponseHandler) {return WBEM_E_NOT_SUPPORTED;};
  127. HRESULT STDMETHODCALLTYPE DeleteInstance(
  128. /* [in] */ const BSTR ObjectPath,
  129. /* [in] */ long lFlags,
  130. /* [in] */ IWbemContext __RPC_FAR *pCtx,
  131. /* [unique][in][out] */ IWbemCallResult __RPC_FAR *__RPC_FAR *ppCallResult) {return WBEM_E_NOT_SUPPORTED;};
  132. HRESULT STDMETHODCALLTYPE DeleteInstanceAsync(
  133. /* [in] */ const BSTR ObjectPath,
  134. /* [in] */ long lFlags,
  135. /* [in] */ IWbemContext __RPC_FAR *pCtx,
  136. /* [in] */ IWbemObjectSink __RPC_FAR *pResponseHandler) {return WBEM_E_NOT_SUPPORTED;};
  137. HRESULT STDMETHODCALLTYPE CreateInstanceEnum(
  138. /* [in] */ const BSTR Class,
  139. /* [in] */ long lFlags,
  140. /* [in] */ IWbemContext __RPC_FAR *pCtx,
  141. /* [out] */ IEnumWbemClassObject __RPC_FAR *__RPC_FAR *ppEnum) {return WBEM_E_NOT_SUPPORTED;};
  142. HRESULT STDMETHODCALLTYPE ExecQuery(
  143. /* [in] */ const BSTR QueryLanguage,
  144. /* [in] */ const BSTR Query,
  145. /* [in] */ long lFlags,
  146. /* [in] */ IWbemContext __RPC_FAR *pCtx,
  147. /* [out] */ IEnumWbemClassObject __RPC_FAR *__RPC_FAR *ppEnum) {return WBEM_E_NOT_SUPPORTED;};
  148. HRESULT STDMETHODCALLTYPE ExecQueryAsync(
  149. /* [in] */ const BSTR QueryLanguage,
  150. /* [in] */ const BSTR Query,
  151. /* [in] */ long lFlags,
  152. /* [in] */ IWbemContext __RPC_FAR *pCtx,
  153. /* [in] */ IWbemObjectSink __RPC_FAR *pResponseHandler) {return WBEM_E_NOT_SUPPORTED;};
  154. HRESULT STDMETHODCALLTYPE ExecNotificationQuery(
  155. /* [in] */ const BSTR QueryLanguage,
  156. /* [in] */ const BSTR Query,
  157. /* [in] */ long lFlags,
  158. /* [in] */ IWbemContext __RPC_FAR *pCtx,
  159. /* [out] */ IEnumWbemClassObject __RPC_FAR *__RPC_FAR *ppEnum) {return WBEM_E_NOT_SUPPORTED;};
  160. HRESULT STDMETHODCALLTYPE ExecNotificationQueryAsync(
  161. /* [in] */ const BSTR QueryLanguage,
  162. /* [in] */ const BSTR Query,
  163. /* [in] */ long lFlags,
  164. /* [in] */ IWbemContext __RPC_FAR *pCtx,
  165. /* [in] */ IWbemObjectSink __RPC_FAR *pResponseHandler) {return WBEM_E_NOT_SUPPORTED;};
  166. HRESULT STDMETHODCALLTYPE ExecMethod( const BSTR, const BSTR, long, IWbemContext*,
  167. IWbemClassObject*, IWbemClassObject**, IWbemCallResult**) {return WBEM_E_NOT_SUPPORTED;}
  168. HRESULT STDMETHODCALLTYPE ExecMethodAsync( const BSTR, const BSTR, long,
  169. IWbemContext*, IWbemClassObject*, IWbemObjectSink*);
  170. protected:
  171. HRESULT AddProps(IWbemClassObject*);
  172. HRESULT WMIPing(
  173. long lFlags,
  174. IWbemContext* pCtx,
  175. IWbemClassObject* pInParams,
  176. IWbemObjectSink* pResultSink);
  177. HRESULT WMIConnectToPort(
  178. long lFlags,
  179. IWbemContext* pCtx,
  180. IWbemClassObject* pInParams,
  181. IWbemObjectSink* pResultSink);
  182. protected:
  183. // All data members for CGotNet should be included here.
  184. } ;
  185. SCODE
  186. CreateInst(
  187. IWbemServices * pNamespace,
  188. IWbemClassObject ** pNewInst,
  189. WCHAR * pwcClassName,
  190. IWbemContext *pCtx);
  191. #endif