summaryrefslogtreecommitdiff
path: root/protocols/Tox/libtox/src/toxcore/tox_log_level.h
blob: 0009ecd54b8c71971162192a0d855e3ce9977eae (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
/* SPDX-License-Identifier: GPL-3.0-or-later
 * Copyright © 2022-2025 The TokTok team.
 */

#ifndef C_TOXCORE_TOXCORE_TOX_LOG_LEVEL_H
#define C_TOXCORE_TOXCORE_TOX_LOG_LEVEL_H

#ifdef __cplusplus
extern "C" {
#endif

/**
 * @brief Severity level of log messages.
 */
typedef enum Tox_Log_Level {
    /**
     * Very detailed traces including all network activity.
     */
    TOX_LOG_LEVEL_TRACE,

    /**
     * Debug messages such as which port we bind to.
     */
    TOX_LOG_LEVEL_DEBUG,

    /**
     * Informational log messages such as video call status changes.
     */
    TOX_LOG_LEVEL_INFO,

    /**
     * Warnings about internal inconsistency or logic errors.
     */
    TOX_LOG_LEVEL_WARNING,

    /**
     * Severe unexpected errors caused by external or internal inconsistency.
     */
    TOX_LOG_LEVEL_ERROR,
} Tox_Log_Level;

const char *tox_log_level_to_string(Tox_Log_Level value);

//!TOKSTYLE-
#ifndef DOXYGEN_IGNORE

#ifndef TOX_HIDE_DEPRECATED
typedef Tox_Log_Level TOX_LOG_LEVEL;
#endif /* TOX_HIDE_DEPRECATED */

#endif
//!TOKSTYLE+

#ifdef __cplusplus
} /* extern "C" */
#endif

#endif /* C_TOXCORE_TOXCORE_TOX_LOG_LEVEL_H */