CG_Labs  2021.2
Classes | Namespaces | Macros | Functions | Variables
Log.cpp File Reference
#include "config.hpp"
#include "Log.h"
#include <cstring>
#include <cstdio>
#include <sstream>
#include <string>
#include <iostream>
#include <thread>
#include <unordered_map>
#include <mutex>

Classes

struct  Log::LogSettings
 

Namespaces

 Log
 

Macros

#define RESULT_MAX_STRING_LENGTH   16384
 

Functions

void Log::Init ()
 
void Log::Destroy ()
 
void Log::SetCustomOutputTargetFunc (void(*textout)(Type, const char *))
 
void Log::SetOutputTargets (size_t flags)
 
void Log::SetVerbosity (Type type, Verbosity verbosity)
 
void Log::SetIncludeThreadID (bool inc)
 
void Log::Report (unsigned int flags, const char *file, const char *function, int line, Type type, const char *str,...)
 
bool Log::ReportParam (unsigned int test, const char *file, const char *function, int line)
 

Variables

FILE * Log::logfile = nullptr
 
void(* Log::textout_func )(Type, const char *) = nullptr
 
std::unordered_map< size_t, size_t > Log::once_map
 
size_t Log::output_targets = LOG_OUT_STD | LOG_OUT_CUSTOM | LOG_OUT_FILE
 
std::mutex Log::fileMutex
 
char Log::log_result_string [RESULT_MAX_STRING_LENGTH]
 
bool Log::logIncludeThreadID = false
 
LogSettings Log::logSettings []
 

Macro Definition Documentation

◆ RESULT_MAX_STRING_LENGTH

#define RESULT_MAX_STRING_LENGTH   16384