Leaked source code of windows server 2003
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.

98 lines
3.0 KiB

  1. /////////////////////////////////////////////////////////////////////////////
  2. //
  3. // Copyright(C) 2000 Microsoft Corporation all rights reserved.
  4. //
  5. // Module: Providers.H
  6. //
  7. // Project: Windows 2000 IAS
  8. //
  9. // Description:
  10. // Declaration of the CProviders class
  11. //
  12. // Author: tperraut
  13. //
  14. // Revision 03/15/2000 created
  15. //
  16. /////////////////////////////////////////////////////////////////////////////
  17. #ifndef _PROVIDERS_H_32E6104C_7547_4b28_A150_5E1E3D080F92
  18. #define _PROVIDERS_H_32E6104C_7547_4b28_A150_5E1E3D080F92
  19. #if _MSC_VER > 1000
  20. #pragma once
  21. #endif // _MSC_VER > 1000
  22. #include "nocopy.h"
  23. #include "basecommand.h"
  24. //////////////////////////////////////////////////////////////////////////////
  25. // class CProvidersAcc
  26. //////////////////////////////////////////////////////////////////////////////
  27. class CProvidersAcc
  28. {
  29. protected:
  30. static const size_t COLUMN_SIZE = 65;
  31. static const size_t NAME_SIZE = 256;
  32. VARIANT_BOOL m_CanConfigure;
  33. VARIANT_BOOL m_IsConfigured;
  34. WCHAR m_Description[NAME_SIZE];
  35. WCHAR m_DLLName[NAME_SIZE];
  36. WCHAR m_Type[COLUMN_SIZE];
  37. WCHAR m_UserDefinedName[COLUMN_SIZE];
  38. BEGIN_COLUMN_MAP(CProvidersAcc)
  39. COLUMN_ENTRY(1, m_UserDefinedName)
  40. COLUMN_ENTRY(2, m_Description)
  41. COLUMN_ENTRY(3, m_Type)
  42. COLUMN_ENTRY(4, m_DLLName)
  43. COLUMN_ENTRY_TYPE(5, DBTYPE_BOOL, m_IsConfigured)
  44. COLUMN_ENTRY_TYPE(6, DBTYPE_BOOL, m_CanConfigure)
  45. END_COLUMN_MAP()
  46. WCHAR m_UserDefinedNameParam[COLUMN_SIZE];
  47. BEGIN_PARAM_MAP(CProvidersAcc)
  48. COLUMN_ENTRY(1, m_UserDefinedNameParam)
  49. END_PARAM_MAP()
  50. DEFINE_COMMAND(CProvidersAcc, L" \
  51. SELECT \
  52. `User Defined Name`, \
  53. Description, \
  54. Type, \
  55. DLLName, \
  56. bIsConfigured, \
  57. bCanConfigure \
  58. FROM Providers \
  59. WHERE `User Defined Name` = ?")
  60. };
  61. //////////////////////////////////////////////////////////////////////////////
  62. // class CProviders
  63. //////////////////////////////////////////////////////////////////////////////
  64. class CProviders : public CBaseCommand<CAccessor<CProvidersAcc> >,
  65. private NonCopyable
  66. {
  67. public:
  68. explicit CProviders(CSession& Session)
  69. {
  70. Init(Session);
  71. }
  72. //////////////////////////////////////////////////////////////////////////
  73. // GetProvider
  74. //////////////////////////////////////////////////////////////////////////
  75. void GetProvider(
  76. const _bstr_t& UserDefinedName,
  77. _bstr_t& Description,
  78. _bstr_t& Type,
  79. _bstr_t& DLLName,
  80. VARIANT_BOOL& IsConfigured,
  81. VARIANT_BOOL& CanConfigure
  82. );
  83. LPCOLESTR GetProviderDescription(const _bstr_t& DPUserDefinedName);
  84. };
  85. #endif // _PROVIDERS_H_32E6104C_7547_4b28_A150_5E1E3D080F92