Ceetron Result Calculator Framework
CRCLogHelper.h
1 //##################################################################################################
2 //
3 // Ceetron Result Calculator Framework
4 //
5 // --------------------------------------------------------------------------------------------
6 // Copyright (C) 2019, Ceetron AS
7 //##################################################################################################
8 #pragma once
9 
10 #include <string>
11 
12 
13 //==================================================================================================
14 //
15 //
16 //
17 //==================================================================================================
19 {
20 public:
21  typedef void(*RawLogFunc)(int level, const char* message);
22 
23 public:
24  inline CRCLogHelper(RawLogFunc rawLogFunc);
25 
26  inline void logError(const std::string& message);
27  inline void logWarning(const std::string& message);
28  inline void logInfo(const std::string& message);
29  inline void logDebug(const std::string& message);
30 
31 private:
32  RawLogFunc m_logFunc;
33 };
34 
35 #include "CRCLogHelper.inl"
36 
void logInfo(const std::string &message)
Log info message.
Definition: CRCLogHelper.inl:59
CRCLogHelper(RawLogFunc rawLogFunc)
Create a helper by providing the rawLogFunc (as provided in the CRC_FrameworkServices) ...
Definition: CRCLogHelper.inl:26
void logDebug(const std::string &message)
Log debug message.
Definition: CRCLogHelper.inl:71
Helper class to do bind to the raw log func provided by the host.
Definition: CRCLogHelper.h:18
void(* RawLogFunc)(int level, const char *message)
The logger function provided by the CRC_FrameworkServices.
Definition: CRCLogHelper.h:21
void logWarning(const std::string &message)
Log warning message.
Definition: CRCLogHelper.inl:47
void logError(const std::string &message)
Log error message.
Definition: CRCLogHelper.inl:35