Aktualizr
C++ SOTA Client
Main Page
Related Pages
Namespaces
Namespace List
Namespace Members
All
Enumerations
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
a
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
Functions
a
c
d
e
f
g
h
i
l
m
o
p
r
s
t
u
v
Variables
Enumerations
Files
File List
File Members
All
Functions
Enumerations
•
All
Classes
Namespaces
Files
Functions
Variables
Enumerations
Enumerator
Pages
src
libaktualizr
logging
logging.h
1
#ifndef SOTA_CLIENT_TOOLS_LOGGING_H_
2
#define SOTA_CLIENT_TOOLS_LOGGING_H_
3
4
#include <boost/log/core.hpp>
5
#include <boost/log/expressions.hpp>
6
#include <boost/log/trivial.hpp>
7
8
struct
LoggerConfig
;
9
10
/** Log an unrecoverable error */
11
#define LOG_FATAL BOOST_LOG_TRIVIAL(fatal)
12
13
/** Log that something has definitely gone wrong */
14
#define LOG_ERROR BOOST_LOG_TRIVIAL(error)
15
16
/** Warn about behaviour that is probably bad, but hasn't yet caused the system
17
* to operate out of spec. */
18
#define LOG_WARNING BOOST_LOG_TRIVIAL(warning)
19
20
/** Report a user-visible message about operation */
21
#define LOG_INFO BOOST_LOG_TRIVIAL(info)
22
23
/** Report a message for developer debugging */
24
#define LOG_DEBUG BOOST_LOG_TRIVIAL(debug)
25
26
/** Report very-verbose debugging information */
27
#define LOG_TRACE BOOST_LOG_TRIVIAL(trace)
28
29
// Use like:
30
// curl_easy_setopt(curl_handle, CURLOPT_VERBOSE, get_curlopt_verbose());
31
int64_t get_curlopt_verbose();
32
33
void
logger_init(
bool
use_colors =
false
);
34
35
void
logger_set_threshold(boost::log::trivial::severity_level threshold);
36
37
void
logger_set_threshold(
const
LoggerConfig
& lconfig);
38
39
void
logger_set_enable(
bool
enabled);
40
41
int
loggerGetSeverity();
42
43
#endif
LoggerConfig
Definition:
config.h:18
Generated by
1.8.17