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.

78 lines
2.3 KiB

  1. /*----------------------------------------------------------------------------
  2. LoadData.h
  3. Header file for return structures to cpsmon.cpp
  4. Copyright (c) 1997-1998 Microsoft Corporation
  5. All rights reserved.
  6. Authors:
  7. t-geetat Geeta Tarachandani
  8. History:
  9. 6/2/97 t-geetat Created
  10. --------------------------------------------------------------------------*/
  11. #include <winperf.h>
  12. #define QUERY_GLOBAL 1
  13. #define QUERY_ITEMS 2
  14. #define QUERY_FOREIGN 3
  15. #define QUERY_COSTLY 4
  16. typedef struct _CPSMON_DATA_DEFINITION
  17. {
  18. PERF_OBJECT_TYPE m_CpsMonObjectType;
  19. PERF_COUNTER_DEFINITION m_CpsMonTotalHits;
  20. PERF_COUNTER_DEFINITION m_CpsMonNoUpgrade;
  21. PERF_COUNTER_DEFINITION m_CpsMonDeltaUpgrade;
  22. PERF_COUNTER_DEFINITION m_CpsMonFullUpgrade;
  23. PERF_COUNTER_DEFINITION m_CpsMonErrors;
  24. PERF_COUNTER_DEFINITION m_CpsMonTotalHitsPerSec;
  25. PERF_COUNTER_DEFINITION m_CpsMonNoUpgradePerSec;
  26. PERF_COUNTER_DEFINITION m_CpsMonDeltaUpgradePerSec;
  27. PERF_COUNTER_DEFINITION m_CpsMonFullUpgradePerSec;
  28. PERF_COUNTER_DEFINITION m_CpsMonErrorsPerSecs;
  29. } CPSMON_DATA_DEFINITION;
  30. #define NUM_OF_INFO_COUNTERS (( sizeof(CPSMON_DATA_DEFINITION) - \
  31. sizeof(PERF_OBJECT_TYPE)) / \
  32. sizeof(PERF_COUNTER_DEFINITION) )
  33. extern CPSMON_DATA_DEFINITION g_CpsMonDataDef;
  34. // The following is for alignment
  35. typedef struct _INFO_COUNTER_BLOCK
  36. {
  37. PERF_COUNTER_BLOCK m_PerfCounterBlock;
  38. LARGE_INTEGER DummyForAlignment;
  39. } INFO_COUNTER_BLOCK;
  40. typedef struct _CPSMON_COUNTERS
  41. {
  42. INFO_COUNTER_BLOCK m_CounterBlock;
  43. DWORD m_dwTotalHits;
  44. DWORD m_dwNoUpgrade;
  45. DWORD m_dwDeltaUpgrade;
  46. DWORD m_dwFullUpgrade;
  47. DWORD m_dwErrors;
  48. DWORD m_dwTotalHitsPerSec;
  49. DWORD m_dwNoUpgradePerSec;
  50. DWORD m_dwDeltaUpgradePerSec;
  51. DWORD m_dwFullUpgradePerSec;
  52. DWORD m_dwErrorsPerSec;
  53. } CPSMON_COUNTERS;
  54. BOOL UpdateDataDefFromRegistry();
  55. void InitializeDataDef();
  56. DWORD GetQueryType ( IN LPWSTR lpValue );
  57. BOOL IsNumberInUnicodeList ( IN DWORD dwNumber, IN LPWSTR lpwszUnicodeList );