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.

70 lines
1.8 KiB

  1. ///////////////////////////////////////////////////////////////////////////////
  2. //
  3. // Copyright (c) 2000, Microsoft Corp. All rights reserved.
  4. //
  5. // FILE
  6. //
  7. // netshhelper.h
  8. //
  9. // SYNOPSIS
  10. //
  11. // Declares the class CIASNetshJetHelper.
  12. //
  13. // MODIFICATION HISTORY
  14. //
  15. // 04/13/2000 Original version.
  16. //
  17. // NOTE: That class was created only to be used from the netsh aaaa helper dll
  18. ///////////////////////////////////////////////////////////////////////////////
  19. #ifndef _NETSH_HELPER_H_
  20. #define _NETSH_HELPER_H_
  21. #if _MSC_VER >= 1000
  22. #pragma once
  23. #endif
  24. #include <atlbase.h>
  25. extern CComModule _Module;
  26. #include <atlcom.h>
  27. #include <datastore2.h>
  28. #include <iasuuid.h>
  29. ///////////////////////////////////////////////////////////////////////////////
  30. //
  31. // CLASS
  32. //
  33. // CIASNetshJetHelper
  34. //
  35. // DESCRIPTION
  36. //
  37. // Provides an Automation compatible wrapper around the Jet Commands used by
  38. // netsh aaaa.
  39. //
  40. ///////////////////////////////////////////////////////////////////////////////
  41. class CIASNetshJetHelper :
  42. public CComObjectRootEx< CComMultiThreadModelNoCS >,
  43. public CComCoClass< CIASNetshJetHelper, &__uuidof(CIASNetshJetHelper) >,
  44. public IIASNetshJetHelper
  45. {
  46. public:
  47. DECLARE_NO_REGISTRY()
  48. DECLARE_NOT_AGGREGATABLE(CIASNetshJetHelper)
  49. BEGIN_COM_MAP(CIASNetshJetHelper)
  50. COM_INTERFACE_ENTRY_IID(__uuidof(IIASNetshJetHelper), IIASNetshJetHelper)
  51. END_COM_MAP()
  52. // IIASNetshJetHelper
  53. STDMETHOD(CloseJetDatabase)();
  54. STDMETHOD(CreateJetDatabase)(BSTR Path);
  55. STDMETHOD(ExecuteSQLCommand)(BSTR Command);
  56. STDMETHOD(ExecuteSQLFunction)(BSTR Command, LONG* Result);
  57. STDMETHOD(OpenJetDatabase)(BSTR Path, VARIANT_BOOL ReadOnly);
  58. STDMETHOD(UpgradeDatabase)();
  59. private:
  60. CComPtr<IUnknown> m_Session;
  61. };
  62. #endif // _NETSH_HELPER_H_