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.

96 lines
2.7 KiB

  1. //***************************************************************************
  2. //
  3. // VPDEFS.H
  4. //
  5. // Module: WBEM VIEW PROVIDER
  6. //
  7. // Copyright (c) 1998-2001 Microsoft Corporation, All Rights Reserved
  8. //
  9. //***************************************************************************
  10. #ifndef _VIEW_PROV_VPDEFS_H
  11. #define _VIEW_PROV_VPDEFS_H
  12. #define VP_QUERY_TIMEOUT 3600000 //1 hour timeout
  13. #define VP_CONNECTION_TIMEOUT 1200000 //20 minute timeout
  14. #define HKEYCLASSES _T("SOFTWARE\\Classes\\")
  15. #define WBEM_CLASS_EXTENDEDSTATUS L"__ExtendedStatus"
  16. #define WBEM_QUERY_LANGUAGE_SQL1 L"WQL"
  17. #define WBEM_PROPERTY_CLASS L"__CLASS"
  18. #define WBEM_PROPERTY_SCLASS L"__SUPERCLASS"
  19. #define WBEM_PROPERTY_DERIVATION L"__DERIVATION"
  20. #define WBEM_PROPERTY_RELPATH L"__RELPATH"
  21. #define WBEM_PROPERTY_NSPACE L"__NAMESPACE"
  22. #define WBEM_PROPERTY_PATH L"__PATH"
  23. #define WBEM_PROPERTY_SERVER L"__SERVER"
  24. #define WBEM_PROPERTY_STATUSCODE L"StatusCode"
  25. #define WBEM_PROPERTY_PROVSTATUSCODE L"ProvStatusCode"
  26. #define WBEM_PROPERTY_PROVSTATUSMESSAGE L"Description"
  27. #define ENUM_INST_QUERY_START L"select * from "
  28. #define ENUM_INST_QUERY_MID L" where __CLASS = \""
  29. #define META_CLASS_QUERY_START L"select * from meta_class where __this isa \""
  30. #define META_CLASS_QUERY_MID L"\" AND __class = \""
  31. #define END_QUOTE L"\""
  32. #define NS_DELIMIT L"::"
  33. //Qualifiers
  34. #define VIEW_QUAL_SOURCES L"ViewSources"
  35. #define VIEW_QUAL_NAMESPACES L"ViewSpaces"
  36. #define VIEW_QUAL_UNION L"Union"
  37. #define VIEW_QUAL_JOIN L"JoinOn"
  38. #define VIEW_QUAL_PROVIDER L"provider"
  39. #define VIEW_QUAL_PROPERTY L"PropertySources"
  40. #define VIEW_QUAL_METHOD L"MethodSource"
  41. #define VIEW_QUAL_FILTER L"PostJoinFilter"
  42. #define VIEW_QUAL_ENUM_CLASS L"EnumerateClasses"
  43. #define VIEW_QUAL_HIDDEN L"HiddenDefault"
  44. #define VIEW_QUAL_KEY L"Key"
  45. #define VIEW_QUAL_ASSOC L"Association"
  46. #define VIEW_QUAL_SNGLTN L"Singleton"
  47. #define VIEW_QUAL_TYPE L"Cimtype"
  48. #define VIEW_QUAL_STATIC L"Static"
  49. #define VIEW_QUAL_DIRECT L"Direct"
  50. //Default key values
  51. #define VIEW_KEY_BOOL_VAL VARIANT_FALSE
  52. #define VIEW_KEY_NUMBER_VAL 0
  53. #define VIEW_KEY_64_VAL L"0"
  54. #define VIEW_KEY_STRING_VAL L"DefaultUnionValue"
  55. #define VIEW_KEY_DATE_VAL L"20000101000000.000000+000"
  56. #define MAX_QUERIES 32
  57. // {AA70DDF4-E11C-11d1-ABB0-00C04FD9159E}
  58. DEFINE_GUID(CLSID_CViewProviderClassFactory,
  59. 0xaa70ddf4, 0xe11c, 0x11d1, 0xab, 0xb0, 0x0, 0xc0, 0x4f, 0xd9, 0x15, 0x9e);
  60. class CFreeBuff
  61. {
  62. private:
  63. void *m_buff;
  64. public:
  65. CFreeBuff(void *buff) : m_buff(buff) {}
  66. void SetBuff(void *buff) { m_buff = buff; }
  67. ~CFreeBuff() { free (m_buff); }
  68. };
  69. #endif //_VIEW_PROV_VPDEFS_H