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.

86 lines
2.1 KiB

  1. //////////////////////////////////////////////////////////////////////////////
  2. //
  3. // Copyright (c) 2000 Microsoft Corporation
  4. //
  5. // Module Name:
  6. // CommonDefs.h
  7. //
  8. // Description:
  9. // This file contains a few definitions common to many classes and files.
  10. //
  11. // Implementation Files:
  12. // None
  13. //
  14. // Maintained By:
  15. // Vij Vasu (Vvasu) 12-MAR-2000
  16. //
  17. //////////////////////////////////////////////////////////////////////////////
  18. // Make sure that this file is included only once per compile path.
  19. #pragma once
  20. //////////////////////////////////////////////////////////////////////////
  21. // Include Files
  22. //////////////////////////////////////////////////////////////////////////
  23. // For some basic types
  24. #include <windows.h>
  25. // For smart classes
  26. #include "SmartClasses.h"
  27. // For DIRID_USER
  28. #include <setupapi.h>
  29. // For IUnknown
  30. #include <Unknwn.h>
  31. //////////////////////////////////////////////////////////////////////////
  32. // Macros definitions
  33. //////////////////////////////////////////////////////////////////////////
  34. // Directory id of the cluster files directory (currently 0x8000, defined in setupapi.h )
  35. #define CLUSTER_DIR_DIRID ( DIRID_USER + 0 )
  36. // Directory id of the localquorum directory.
  37. #define CLUSTER_LOCALQUORUM_DIRID ( DIRID_USER + 1 )
  38. //////////////////////////////////////////////////////////////////////////
  39. // Type definitions
  40. //////////////////////////////////////////////////////////////////////////
  41. // Types of cluster configuration actions.
  42. typedef enum
  43. {
  44. eCONFIG_ACTION_NONE = -1
  45. , eCONFIG_ACTION_FORM
  46. , eCONFIG_ACTION_JOIN
  47. , eCONFIG_ACTION_CLEANUP
  48. , eCONFIG_ACTION_UPGRADE
  49. , eCONFIG_ACTION_MAX
  50. } EBaseConfigAction;
  51. //
  52. // Smart classes
  53. //
  54. // Smart WCHAR array.
  55. typedef CSmartGenericPtr< CPtrTrait< WCHAR > > SmartSz;
  56. // Smart BYTE array.
  57. typedef CSmartGenericPtr< CArrayPtrTrait< BYTE > > SmartByteArray;
  58. // Smart SC Manager handle.
  59. typedef CSmartResource<
  60. CHandleTrait<
  61. SC_HANDLE
  62. , BOOL
  63. , CloseServiceHandle
  64. , reinterpret_cast< SC_HANDLE >( NULL )
  65. >
  66. > SmartSCMHandle;