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.

94 lines
1.5 KiB

  1. ///////////////////////////////////////////////////////////////////////////////
  2. //
  3. // Copyright (c) Microsoft Corporation
  4. //
  5. // SYNOPSIS
  6. //
  7. // Declares he API into the IAS trace facility.
  8. //
  9. ///////////////////////////////////////////////////////////////////////////////
  10. #ifndef IASTRACE_H
  11. #define IASTRACE_H
  12. #pragma once
  13. #ifdef __cplusplus
  14. extern "C" {
  15. #endif
  16. VOID
  17. WINAPI
  18. IASTraceInitialize( VOID );
  19. VOID
  20. WINAPI
  21. IASTraceUninitialize( VOID );
  22. DWORD
  23. WINAPI
  24. IASFormatSysErr(
  25. IN DWORD dwError,
  26. IN PSTR lpBuffer,
  27. IN DWORD nSize
  28. );
  29. VOID
  30. WINAPIV
  31. IASTracePrintf(
  32. IN PCSTR szFormat,
  33. ...
  34. );
  35. VOID
  36. WINAPI
  37. IASTraceString(
  38. IN PCSTR szString
  39. );
  40. VOID
  41. WINAPI
  42. IASTraceBinary(
  43. IN CONST BYTE* lpbBytes,
  44. IN DWORD dwByteCount
  45. );
  46. VOID
  47. WINAPI
  48. IASTraceFailure(
  49. IN PCSTR szFunction,
  50. IN DWORD dwError
  51. );
  52. //////////
  53. // This can only be called from inside a C++ catch block. If you call it
  54. // anywhere else you will probably crash the process.
  55. //////////
  56. VOID
  57. WINAPI
  58. IASTraceExcept( VOID );
  59. #ifdef __cplusplus
  60. }
  61. class IASTraceInitializer
  62. {
  63. public:
  64. IASTraceInitializer() throw ()
  65. {
  66. IASTraceInitialize();
  67. }
  68. ~IASTraceInitializer() throw ()
  69. {
  70. IASTraceUninitialize();
  71. }
  72. private:
  73. // Not implemented.
  74. IASTraceInitializer(const IASTraceInitializer&);
  75. IASTraceInitializer& operator=(const IASTraceInitializer&);
  76. };
  77. #endif
  78. #endif // IASTRACE_H