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.

46 lines
1.1 KiB

  1. // DbgLvl.h : This file contains the
  2. // Created: Dec '97
  3. // Author : a-rakeba
  4. // History:
  5. // Copyright (C) 1997 Microsoft Corporation
  6. // All rights reserved.
  7. // Microsoft Confidential
  8. #if !defined( _DBGLVL_H_ )
  9. #define _DBGLVL_H_
  10. #include "cmnhdr.h"
  11. #include <windows.h>
  12. namespace _Utils {
  13. class CDebugLevel {
  14. friend class CDebugLogger;
  15. public:
  16. enum { TRACE_DEBUGGING = 0x00000001, DBG_RECVD_CHARS = 0x00000002,
  17. DBG_SENT_CHARS = 0x00000004, DBG_NEGOTIATION = 0x00000008,
  18. DBG_THREADS = 0x00000010, TRACE_HANDLE = 0x00000020,
  19. TRACE_SOCKET = 0x00000040
  20. };
  21. private:
  22. static void TurnOn( DWORD dwLvl );
  23. static void TurnOnAll( void );
  24. static void TurnOff( DWORD dwLvl );
  25. static void TurnOffAll( void );
  26. static bool IsCurrLevel( DWORD dwLvl );
  27. CDebugLevel();
  28. ~CDebugLevel();
  29. static DWORD s_dwLevel;
  30. };
  31. }
  32. #endif // _DBGLVL_H_
  33. // Notes:
  34. // This class is not made thread-safe, since it's purpose in life
  35. // is to be called from thread-safe code in CDebugLogger