48 lines
2.4 KiB
C++
48 lines
2.4 KiB
C++
////////////////////////////////////////////////////////////////////////////////
|
|
// (c) Copyright, Ubisoft Entertainment Inc. || Created by Harbour //
|
|
////////////////////////////////////////////////////////////////////////////////
|
|
#pragma once
|
|
#include "ubiservices/core/configs/config.h"
|
|
#include "ubiservices/core/log/eventLogConstants.h"
|
|
|
|
namespace US_NS {;
|
|
|
|
/// Provides the API to configure developer logging provided by the SDK.
|
|
// This is a struct because swig is not able to generate C# files for namespaces with static functions. Swig "flattens" namespaces.
|
|
struct US_DLL_API LoggingHelper
|
|
{
|
|
/// Enables verbose logging for problem diagnostic.
|
|
static void enableVerbose(bool state = true);
|
|
|
|
/// Enables the specified category of log entries.
|
|
/// @param category The log events category to enable
|
|
/// @param scope A flag indicating to disable other categories (or not)
|
|
/// @note The filtering affects all facade instances logging.
|
|
static void enableCategory(LogCategory category, EnableScope scope = EnableScope::DisablingOthers);
|
|
|
|
/// Disables the specified category of log entries.
|
|
/// Disabling a category filters out the entries of that category.
|
|
/// @param category The log events category to disable
|
|
/// @param scope A flag indicating to enable other categories (or not)
|
|
/// @note The filtering affects all facade instances logging.
|
|
static void disableCategory(LogCategory category, DisableScope scope = DisableScope::NotEnablingOthers);
|
|
|
|
/// Sets the level of event logs.
|
|
/// Messages with a level lower than the specified level are not displayed.
|
|
/// @param level The log level threshold.
|
|
/// @note The filtering affects all facade instances logging.
|
|
static void setLevel(LogLevel level);
|
|
|
|
/// Sets the level of event logs for a category.
|
|
/// Messages with a level lower than the specified level are not displayed.
|
|
/// @param category The log event category to change its level threshold.
|
|
/// @param level The log level threshold.
|
|
/// @note The filtering affects all facade instances logging.
|
|
static void setCategoryLevel(LogCategory category, LogLevel level);
|
|
|
|
/// Enable the logging of long messages on multiple lines to ease reading.
|
|
/// @param state True, display on multiple lines. False, display on a single line.
|
|
static void enableMultiLines(bool state = true);
|
|
};
|
|
|
|
};
|