//----------------------------------------------------------------------------------------------------------------------
/// \file
/// Public logging interface for C++ tests.
// Copyright (c) Microsoft Corporation. All Rights Reserved.
//----------------------------------------------------------------------------------------------------------------------
#pragma once
#include "Wex.Logger.h"
#include "LogTestResults.h"
#include "WexLogTrace.h"
#include "WexTypes.h"
// Allow anyone who has defined an Assert, Log, LogTrace, or Trace macro to compile with this header file included
#pragma push_macro("Assert")
#undef Assert
#pragma push_macro("Log")
#undef Log
#pragma push_macro("LogTrace")
#undef LogTrace
#pragma push_macro("Trace")
#undef Trace
namespace WEX { namespace Logging { namespace Private
{
extern "C" WEXLOGGER_API void WEXLOGGER_STDCALL Log_Trace(LogTrace&& trace) noexcept;
extern "C" WEXLOGGER_API void WEXLOGGER_STDCALL Log_MiniDump() noexcept;
}/* namespace Private */}/* namespace Logging */}/* namespace WEX */
namespace WEX { namespace Logging { namespace Log
{
///
/// Log a trace
///
///
inline void Trace(LogTrace&& trace) noexcept
{
Private::Log_Trace(static_cast(trace));
}
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test assert
///
///
inline void Assert(const wchar_t* pszAssert) noexcept
{
Trace(AssertTrace{pszAssert});
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test assert
///
///
inline void Assert(const char* pszAssert) noexcept
{
Trace(AssertTrace{pszAssert});
}
#if defined(__cpp_char8_t)
inline void Assert(const char8_t* pszAssert) noexcept
{
Trace(AssertTrace{pszAssert});
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test assert
///
///
///
inline void Assert(const wchar_t* pszAssert, const wchar_t* pszContext) noexcept
{
Trace(AssertTrace{pszAssert}.WithContext(pszContext));
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test assert
///
///
///
inline void Assert(const char* pszAssert, const char* pszContext) noexcept
{
Trace(AssertTrace{pszAssert}.WithContext(pszContext));
}
#if defined(__cpp_char8_t)
inline void Assert(const char8_t* pszAssert, const char8_t* pszContext) noexcept
{
Trace(AssertTrace{pszAssert}.WithContext(pszContext));
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test assert
///
///
///
///
///
inline void Assert(const wchar_t* pszAssert, const wchar_t* pszFile, const wchar_t* pszFunction, int line) noexcept
{
Trace(AssertTrace{pszAssert}.WithSourceInfo(pszFile, pszFunction, line));
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test assert
///
///
///
///
///
inline void Assert(const char* pszAssert, const char* pszFile, const char* pszFunction, int line) noexcept
{
Trace(AssertTrace{pszAssert}.WithSourceInfo(pszFile, pszFunction, line));
}
#if defined(__cpp_char8_t)
inline void Assert(const char8_t* pszAssert, const char* pszFile, const char* pszFunction, int line) noexcept
{
Trace(AssertTrace{pszAssert}.WithSourceInfo(pszFile, pszFunction, line));
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test assert
///
///
///
///
///
///
inline void Assert(const wchar_t* pszAssert, const wchar_t* pszContext, const wchar_t* pszFile, const wchar_t* pszFunction, int line) noexcept
{
Trace(AssertTrace{pszAssert}.WithContext(pszContext).WithSourceInfo(pszFile, pszFunction, line));
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test assert
///
///
///
///
///
///
inline void Assert(const char* pszAssert, const char* pszContext, const char* pszFile, const char* pszFunction, int line) noexcept
{
Trace(AssertTrace{pszAssert}.WithContext(pszContext).WithSourceInfo(pszFile, pszFunction, line));
}
#if defined(__cpp_char8_t)
inline void Assert(const char8_t* pszAssert, const char8_t* pszContext, const char* pszFile, const char* pszFunction, int line) noexcept
{
Trace(AssertTrace{pszAssert}.WithContext(pszContext).WithSourceInfo(pszFile, pszFunction, line));
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a known bug number
///
///
///
inline void Bug(const wchar_t* pszBugDatabase, int bugId) noexcept
{
Trace(BugTrace{pszBugDatabase, bugId});
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a known bug number
///
///
///
inline void Bug(const char* pszBugDatabase, int bugId) noexcept
{
Trace(BugTrace{pszBugDatabase, bugId});
}
#if defined(__cpp_char8_t)
inline void Bug(const char8_t* pszBugDatabase, int bugId) noexcept
{
Trace(BugTrace{pszBugDatabase, bugId});
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a known bug number
///
///
///
///
inline void Bug(const wchar_t* pszBugDatabase, int bugId, const wchar_t* pszContext) noexcept
{
Trace(BugTrace{pszBugDatabase, bugId}.WithContext(pszContext));
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a known bug number
///
///
///
///
inline void Bug(const char* pszBugDatabase, int bugId, const char* pszContext) noexcept
{
Trace(BugTrace{pszBugDatabase, bugId}.WithContext(pszContext));
}
#if defined(__cpp_char8_t)
inline void Bug(const char8_t* pszBugDatabase, int bugId, const char8_t* pszContext) noexcept
{
Trace(BugTrace{pszBugDatabase, bugId}.WithContext(pszContext));
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test comment
///
///
inline void Comment(const wchar_t* pszComment) noexcept
{
Trace(CommentTrace{pszComment});
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test comment
///
///
inline void Comment(const char* pszComment) noexcept
{
Trace(CommentTrace{pszComment});
}
#if defined(__cpp_char8_t)
inline void Comment(const char8_t* pszComment) noexcept
{
Trace(CommentTrace{pszComment});
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test comment
///
///
///
inline void Comment(const wchar_t* pszComment, const wchar_t* pszContext) noexcept
{
Trace(CommentTrace{pszComment}.WithContext(pszContext));
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test comment
///
///
///
inline void Comment(const char* pszComment, const char* pszContext) noexcept
{
Trace(CommentTrace{pszComment}.WithContext(pszContext));
}
#if defined(__cpp_char8_t)
inline void Comment(const char8_t* pszComment, const char8_t* pszContext) noexcept
{
Trace(CommentTrace{pszComment}.WithContext(pszContext));
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log the end of a group of tests, or of a specific test
///
///
inline void EndGroup(const wchar_t* pszGroupName) noexcept
{
Trace(EndGroupTrace{pszGroupName});
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log the end of a group of tests, or of a specific test
///
///
inline void EndGroup(const char* pszGroupName) noexcept
{
Trace(EndGroupTrace{pszGroupName});
}
#if defined(__cpp_char8_t)
inline void EndGroup(const char8_t* pszGroupName) noexcept
{
Trace(EndGroupTrace{pszGroupName});
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log the end of a group of tests, or of a specific test
///
///
///
inline void EndGroup(const wchar_t* pszGroupName, const wchar_t* pszContext) noexcept
{
Trace(EndGroupTrace{pszGroupName}.WithContext(pszContext));
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log the end of a group of tests, or of a specific test
///
///
///
inline void EndGroup(const char* pszGroupName, const char* pszContext) noexcept
{
Trace(EndGroupTrace{pszGroupName}.WithContext(pszContext));
}
#if defined(__cpp_char8_t)
inline void EndGroup(const char8_t* pszGroupName, const char8_t* pszContext) noexcept
{
Trace(EndGroupTrace{pszGroupName}.WithContext(pszContext));
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test error
///
///
inline void Error(const wchar_t* pszError) noexcept
{
Trace(ErrorTrace{pszError});
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test error
///
///
inline void Error(const char* pszError) noexcept
{
Trace(ErrorTrace{pszError});
}
#if defined(__cpp_char8_t)
inline void Error(const char8_t* pszError) noexcept
{
Trace(ErrorTrace{pszError});
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test error
///
///
///
inline void Error(const wchar_t* pszError, const wchar_t* pszContext) noexcept
{
Trace(ErrorTrace{pszError}.WithContext(pszContext));
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test error
///
///
///
inline void Error(const char* pszError, const char* pszContext) noexcept
{
Trace(ErrorTrace{pszError}.WithContext(pszContext));
}
#if defined(__cpp_char8_t)
inline void Error(const char8_t* pszError, const char8_t* pszContext) noexcept
{
Trace(ErrorTrace{pszError}.WithContext(pszContext));
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test error
///
///
///
///
///
inline void Error(const wchar_t* pszError, const wchar_t* pszFile, const wchar_t* pszFunction, int line) noexcept
{
Trace(ErrorTrace{pszError}.WithSourceInfo(pszFile, pszFunction, line));
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test error
///
///
///
///
///
inline void Error(const char* pszError, const char* pszFile, const char* pszFunction, int line) noexcept
{
Trace(ErrorTrace{pszError}.WithSourceInfo(pszFile, pszFunction, line));
}
#if defined(__cpp_char8_t)
inline void Error(const char8_t* pszError, const char* pszFile, const char* pszFunction, int line) noexcept
{
Trace(ErrorTrace{pszError}.WithSourceInfo(pszFile, pszFunction, line));
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test error
///
///
///
///
///
///
inline void Error(const wchar_t* pszError, const wchar_t* pszContext, const wchar_t* pszFile, const wchar_t* pszFunction, int line) noexcept
{
Trace(ErrorTrace{pszError}.WithContext(pszContext).WithSourceInfo(pszFile, pszFunction, line));
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test error
///
///
///
///
///
///
inline void Error(const char* pszError, const char* pszContext, const char* pszFile, const char* pszFunction, int line) noexcept
{
Trace(ErrorTrace{pszError}.WithContext(pszContext).WithSourceInfo(pszFile, pszFunction, line));
}
#if defined(__cpp_char8_t)
inline void Error(const char8_t* pszError, const char8_t* pszContext, const char* pszFile, const char* pszFunction, int line) noexcept
{
Trace(ErrorTrace{pszError}.WithContext(pszContext).WithSourceInfo(pszFile, pszFunction, line));
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test file to be saved to disk
///
///
inline void File(const wchar_t* pszFilePath) noexcept
{
Trace(FileTrace{pszFilePath});
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test file to be saved to disk
///
///
inline void File(const char* pszFilePath) noexcept
{
Trace(FileTrace{pszFilePath});
}
#if defined(__cpp_char8_t)
inline void File(const char8_t* pszFilePath) noexcept
{
Trace(FileTrace{pszFilePath});
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test file to be saved to disk
///
///
///
inline void File(const wchar_t* pszFilePath, const wchar_t* pszContext) noexcept
{
Trace(FileTrace{pszFilePath}.WithContext(pszContext));
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test file to be saved to disk
///
///
///
inline void File(const char* pszFilePath, const char* pszContext) noexcept
{
Trace(FileTrace{pszFilePath}.WithContext(pszContext));
}
#if defined(__cpp_char8_t)
inline void File(const char8_t* pszFilePath, const char8_t* pszContext) noexcept
{
Trace(FileTrace{pszFilePath}.WithContext(pszContext));
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test file (in byte array form) to be saved to disk
///
///
///
///
inline void File(const wchar_t* pszFileName, const unsigned char* pFileBuffer, size_t bufferSize) noexcept
{
Trace(FileTrace{pszFileName, pFileBuffer, bufferSize});
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test file (in byte array form) to be saved to disk
///
///
///
///
inline void File(const char* pszFileName, const unsigned char* pFileBuffer, size_t bufferSize) noexcept
{
Trace(FileTrace{pszFileName, pFileBuffer, bufferSize});
}
#if defined(__cpp_char8_t)
inline void File(const char8_t* pszFileName, const unsigned char* pFileBuffer, size_t bufferSize) noexcept
{
Trace(FileTrace{pszFileName, pFileBuffer, bufferSize});
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test file (in byte array form) to be saved
///
///
///
///
///
inline void File(const wchar_t* pszFileName, const wchar_t* pszContext, const unsigned char* pFileBuffer, size_t bufferSize) noexcept
{
Trace(FileTrace{pszFileName, pFileBuffer, bufferSize}.WithContext(pszContext));
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test file (in byte array form) to be saved
///
///
///
///
///
inline void File(const char* pszFileName, const char* pszContext, const unsigned char* pFileBuffer, size_t bufferSize) noexcept
{
Trace(FileTrace{pszFileName, pFileBuffer, bufferSize}.WithContext(pszContext));
}
#if defined(__cpp_char8_t)
inline void File(const char8_t* pszFileName, const char8_t* pszContext, const unsigned char* pFileBuffer, size_t bufferSize) noexcept
{
Trace(FileTrace{pszFileName, pFileBuffer, bufferSize}.WithContext(pszContext));
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a name/value property pair the value can be in xml format
///
///
///
inline void Property(const wchar_t* pszName, const wchar_t* pszValue) noexcept
{
Trace(PropertyTrace{pszName, pszValue});
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a name/value property pair the value can be in xml format
///
///
///
inline void Property(const char* pszName, const char* pszValue) noexcept
{
Trace(PropertyTrace{pszName, pszValue});
}
#if defined(__cpp_char8_t)
inline void Property(const char8_t* pszName, const char8_t* pszValue) noexcept
{
Trace(PropertyTrace{pszName, pszValue});
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a name/value property pair; the value can be in xml format
///
///
///
///
inline void Property(const wchar_t* pszName, const wchar_t* pszValue, const wchar_t* pszContext) noexcept
{
Trace(PropertyTrace{pszName, pszValue}.WithContext(pszContext));
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a name/value property pair; the value can be in xml format
///
///
///
///
inline void Property(const char* pszName, const char* pszValue, const char* pszContext) noexcept
{
Trace(PropertyTrace{pszName, pszValue}.WithContext(pszContext));
}
#if defined(__cpp_char8_t)
inline void Property(const char8_t* pszName, const char8_t* pszValue, const char8_t* pszContext) noexcept
{
Trace(PropertyTrace{pszName, pszValue}.WithContext(pszContext));
}
#endif // #if defined(__cpp_char8_t)
///
/// Log a test result
///
///
inline void Result(TestResults::Result testResult) noexcept
{
Trace(ResultTrace{testResult});
}
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test result
///
///
///
inline void Result(TestResults::Result testResult, const wchar_t* pszComment) noexcept
{
Trace(ResultTrace{testResult, pszComment});
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test result
///
///
///
inline void Result(TestResults::Result testResult, const char* pszComment) noexcept
{
Trace(ResultTrace{testResult, pszComment});
}
#if defined(__cpp_char8_t)
inline void Result(TestResults::Result testResult, const char8_t* pszComment) noexcept
{
Trace(ResultTrace{testResult, pszComment});
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test result
///
///
///
///
inline void Result(TestResults::Result testResult, const wchar_t* pszComment, const wchar_t* pszContext) noexcept
{
Trace(ResultTrace{testResult, pszComment}.WithContext(pszContext));
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test result
///
///
///
///
inline void Result(TestResults::Result testResult, const char* pszComment, const char* pszContext) noexcept
{
Trace(ResultTrace{testResult, pszComment}.WithContext(pszContext));
}
#if defined(__cpp_char8_t)
inline void Result(TestResults::Result testResult, const char8_t* pszComment, const char8_t* pszContext) noexcept
{
Trace(ResultTrace{testResult, pszComment}.WithContext(pszContext));
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log the start of a group of tests, or of a specific test
///
///
inline void StartGroup(const wchar_t* pszGroupName) noexcept
{
Trace(StartGroupTrace{pszGroupName});
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log the start of a group of tests, or of a specific test
///
///
inline void StartGroup(const char* pszGroupName) noexcept
{
Trace(StartGroupTrace{pszGroupName});
}
#if defined(__cpp_char8_t)
inline void StartGroup(const char8_t* pszGroupName) noexcept
{
Trace(StartGroupTrace{pszGroupName});
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log the start of a group of tests, or of a specific test; also sets the default test result
///
///
///
inline void StartGroup(const wchar_t* pszGroupName, TestResults::Result defaultTestResult) noexcept
{
Trace(StartGroupTrace{pszGroupName, defaultTestResult});
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log the start of a group of tests, or of a specific test; also sets the default test result
///
///
///
inline void StartGroup(const char* pszGroupName, TestResults::Result defaultTestResult) noexcept
{
Trace(StartGroupTrace{pszGroupName, defaultTestResult});
}
#if defined(__cpp_char8_t)
inline void StartGroup(const char8_t* pszGroupName, TestResults::Result defaultTestResult) noexcept
{
Trace(StartGroupTrace{pszGroupName, defaultTestResult});
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log the start of a group of tests, or of a specific test
///
///
///
inline void StartGroup(const wchar_t* pszGroupName, const wchar_t* pszContext) noexcept
{
Trace(StartGroupTrace{pszGroupName}.WithContext(pszContext));
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log the start of a group of tests, or of a specific test
///
///
///
inline void StartGroup(const char* pszGroupName, const char* pszContext) noexcept
{
Trace(StartGroupTrace{pszGroupName}.WithContext(pszContext));
}
#if defined(__cpp_char8_t)
inline void StartGroup(const char8_t* pszGroupName, const char8_t* pszContext) noexcept
{
Trace(StartGroupTrace{pszGroupName}.WithContext(pszContext));
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log the start of a group of tests, or of a specific test; also sets the default test result
///
///
///
///
inline void StartGroup(const wchar_t* pszGroupName, const wchar_t* pszContext, TestResults::Result defaultTestResult) noexcept
{
Trace(StartGroupTrace{pszGroupName, defaultTestResult}.WithContext(pszContext));
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log the start of a group of tests, or of a specific test; also sets the default test result
///
///
///
///
inline void StartGroup(const char* pszGroupName, const char* pszContext, TestResults::Result defaultTestResult) noexcept
{
Trace(StartGroupTrace{pszGroupName, defaultTestResult}.WithContext(pszContext));
}
#if defined(__cpp_char8_t)
inline void StartGroup(const char8_t* pszGroupName, const char8_t* pszContext, TestResults::Result defaultTestResult) noexcept
{
Trace(StartGroupTrace{pszGroupName, defaultTestResult}.WithContext(pszContext));
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test warning
///
///
inline void Warning(const wchar_t* pszWarning) noexcept
{
Trace(WarningTrace{pszWarning});
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test warning
///
///
inline void Warning(const char* pszWarning) noexcept
{
Trace(WarningTrace{pszWarning});
}
#if defined(__cpp_char8_t)
inline void Warning(const char8_t* pszWarning) noexcept
{
Trace(WarningTrace{pszWarning});
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test warning
///
///
///
inline void Warning(const wchar_t* pszWarning, const wchar_t* pszContext) noexcept
{
Trace(WarningTrace{pszWarning}.WithContext(pszContext));
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test warning
///
///
///
inline void Warning(const char* pszWarning, const char* pszContext) noexcept
{
Trace(WarningTrace{pszWarning}.WithContext(pszContext));
}
#if defined(__cpp_char8_t)
inline void Warning(const char8_t* pszWarning, const char8_t* pszContext) noexcept
{
Trace(WarningTrace{pszWarning}.WithContext(pszContext));
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test warning
///
///
///
///
///
inline void Warning(const wchar_t* pszWarning, const wchar_t* pszFile, const wchar_t* pszFunction, int line) noexcept
{
Trace(WarningTrace{pszWarning}.WithSourceInfo(pszFile, pszFunction, line));
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test warning
///
///
///
///
///
inline void Warning(const char* pszWarning, const char* pszFile, const char* pszFunction, int line) noexcept
{
Trace(WarningTrace{pszWarning}.WithSourceInfo(pszFile, pszFunction, line));
}
#if defined(__cpp_char8_t)
inline void Warning(const char8_t* pszWarning, const char* pszFile, const char* pszFunction, int line) noexcept
{
Trace(WarningTrace{pszWarning}.WithSourceInfo(pszFile, pszFunction, line));
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test warning
///
///
///
///
///
///
inline void Warning(const wchar_t* pszWarning, const wchar_t* pszContext, const wchar_t* pszFile, const wchar_t* pszFunction, int line) noexcept
{
Trace(WarningTrace{pszWarning}.WithContext(pszContext).WithSourceInfo(pszFile, pszFunction, line));
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log a test warning
///
///
///
///
///
///
inline void Warning(const char* pszWarning, const char* pszContext, const char* pszFile, const char* pszFunction, int line) noexcept
{
Trace(WarningTrace{pszWarning}.WithContext(pszContext).WithSourceInfo(pszFile, pszFunction, line));
}
#if defined(__cpp_char8_t)
inline void Warning(const char8_t* pszWarning, const char8_t* pszContext, const char* pszFile, const char* pszFunction, int line) noexcept
{
Trace(WarningTrace{pszWarning}.WithContext(pszContext).WithSourceInfo(pszFile, pszFunction, line));
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log xml data; no check is made to verify that it is well-formed
///
///
inline void Xml(const wchar_t* pszXml) noexcept
{
Trace(XmlTrace{pszXml});
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log xml data; no check is made to verify that it is well-formed
///
///
inline void Xml(const char* pszXml) noexcept
{
Trace(XmlTrace{pszXml});
}
#if defined(__cpp_char8_t)
inline void Xml(const char8_t* pszXml) noexcept
{
Trace(XmlTrace{pszXml});
}
#endif // #if defined(__cpp_char8_t)
#if !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log xml data; no check is made to verify that it is well-formed
///
///
///
inline void Xml(const wchar_t* pszXml, const wchar_t* pszContext) noexcept
{
Trace(XmlTrace{pszXml}.WithContext(pszContext));
}
#endif // !defined(WEX_LOGGER_NO_WCHAR_API)
///
/// Log xml data; no check is made to verify that it is well-formed
///
///
///
inline void Xml(const char* pszXml, const char* pszContext) noexcept
{
Trace(XmlTrace{pszXml}.WithContext(pszContext));
}
#if defined(__cpp_char8_t)
inline void Xml(const char8_t* pszXml, const char8_t* pszContext) noexcept
{
Trace(XmlTrace{pszXml}.WithContext(pszContext));
}
#endif // #if defined(__cpp_char8_t)
#if defined(_WIN32)
///
/// Log the current process mini dump
///
inline void MiniDump() noexcept
{
Private::Log_MiniDump();
}
#endif // _WIN32
}/* namespace Log */}/* namespace Logging */}/* namespace WEX */
#pragma pop_macro("Trace")
#pragma pop_macro("LogTrace")
#pragma pop_macro("Log")
#pragma pop_macro("Assert")