kim-api-v2
2.0.1+cc5c14a.GNU
An Application Programming Interface (API) for the Knowledgebase of Interatomic Models (KIM).
v2.0.1
c
include
KIM_LogMacros.h
Go to the documentation of this file.
1
/* */
2
/* CDDL HEADER START */
3
/* */
4
/* The contents of this file are subject to the terms of the Common */
5
/* Development and Distribution License Version 1.0 (the "License"). */
6
/* */
7
/* You can obtain a copy of the license at */
8
/* http://www.opensource.org/licenses/CDDL-1.0. See the License for the */
9
/* specific language governing permissions and limitations under the License. */
10
/* */
11
/* When distributing Covered Code, include this CDDL HEADER in each file and */
12
/* include the License file in a prominent location with the name */
13
/* LICENSE.CDDL. */
14
/* If applicable, add the following below this CDDL HEADER, with the fields */
15
/* enclosed by brackets "[]" replaced with your own identifying information: */
16
/* */
17
/* Portions Copyright (c) [yyyy] [name of copyright owner]. */
18
/* All rights reserved. */
19
/* */
20
/* CDDL HEADER END */
21
/* */
22
23
/* */
24
/* Copyright (c) 2016--2019, Regents of the University of Minnesota. */
25
/* All rights reserved. */
26
/* */
27
/* Contributors: */
28
/* Ryan S. Elliott */
29
/* */
30
31
/* */
32
/* Release: This file is part of the kim-api-v2-2.0.1 package. */
33
/* */
34
35
36
#undef FATAL_VERBOSITY
37
40
#define FATAL_VERBOSITY (KIM_LOG_MAXIMUM_LEVEL >= KIM_LOG_VERBOSITY_FATAL_)
41
#undef LOG_FATAL
42
#if (KIM_LOG_MAXIMUM_LEVEL >= KIM_LOG_VERBOSITY_FATAL_)
43
48
#define LOG_FATAL(message) \
49
KIM_LOGGER_FUNCTION_NAME(KIM_LOGGER_OBJECT_NAME, \
50
KIM_LOG_VERBOSITY_fatal, \
51
message, \
52
__LINE__, \
53
__FILE__)
54
#else
55
#define LOG_FATAL(message)
56
#endif
57
58
#undef ERROR_VERBOSITY
59
62
#define ERROR_VERBOSITY (KIM_LOG_MAXIMUM_LEVEL >= KIM_LOG_VERBOSITY_ERROR_)
63
#undef LOG_ERROR
64
#if (KIM_LOG_MAXIMUM_LEVEL >= KIM_LOG_VERBOSITY_ERROR_)
65
70
#define LOG_ERROR(message) \
71
KIM_LOGGER_FUNCTION_NAME(KIM_LOGGER_OBJECT_NAME, \
72
KIM_LOG_VERBOSITY_error, \
73
message, \
74
__LINE__, \
75
__FILE__)
76
#else
77
#define LOG_ERROR(message)
78
#endif
79
80
#undef WARNING_VERBOSITY
81
84
#define WARNING_VERBOSITY (KIM_LOG_MAXIMUM_LEVEL >= KIM_LOG_VERBOSITY_WARNING_)
85
#undef LOG_WARNING
86
#if (KIM_LOG_MAXIMUM_LEVEL >= KIM_LOG_VERBOSITY_WARNING_)
87
92
#define LOG_WARNING(message) \
93
KIM_LOGGER_FUNCTION_NAME(KIM_LOGGER_OBJECT_NAME, \
94
KIM_LOG_VERBOSITY_warning, \
95
message, \
96
__LINE__, \
97
__FILE__)
98
#else
99
#define LOG_WARNING(message)
100
#endif
101
102
#undef INFORMATION_VERBOSITY
103
106
#define INFORMATION_VERBOSITY \
107
(KIM_LOG_MAXIMUM_LEVEL >= KIM_LOG_VERBOSITY_INFORMATION_)
108
#undef LOG_INFORMATION
109
#if (KIM_LOG_MAXIMUM_LEVEL >= KIM_LOG_VERBOSITY_INFORMATION_)
110
115
#define LOG_INFORMATION(message) \
116
KIM_LOGGER_FUNCTION_NAME(KIM_LOGGER_OBJECT_NAME, \
117
KIM_LOG_VERBOSITY_information, \
118
message, \
119
__LINE__, \
120
__FILE__)
121
#else
122
#define LOG_INFORMATION(message)
123
#endif
124
125
#undef DEBUG_VERBOSITY
126
129
#define DEBUG_VERBOSITY (KIM_LOG_MAXIMUM_LEVEL >= KIM_LOG_VERBOSITY_DEBUG_)
130
#undef LOG_DEBUG
131
#if (KIM_LOG_MAXIMUM_LEVEL >= KIM_LOG_VERBOSITY_DEBUG_)
132
137
#define LOG_DEBUG(message) \
138
KIM_LOGGER_FUNCTION_NAME(KIM_LOGGER_OBJECT_NAME, \
139
KIM_LOG_VERBOSITY_debug, \
140
message, \
141
__LINE__, \
142
__FILE__)
143
#else
144
#define LOG_DEBUG(message)
145
#endif
Generated by
1.8.13