19 #ifndef GRPC_IMPL_CODEGEN_LOG_H
20 #define GRPC_IMPL_CODEGEN_LOG_H
49 #define GPR_LOG_VERBOSITY_UNSET -1
55 #define GPR_DEBUG __FILE__, __LINE__, GPR_LOG_SEVERITY_DEBUG
56 #define GPR_INFO __FILE__, __LINE__, GPR_LOG_SEVERITY_INFO
57 #define GPR_ERROR __FILE__, __LINE__, GPR_LOG_SEVERITY_ERROR
94 #define GPR_ASSERT(x) \
96 if (GPR_UNLIKELY(!(x))) { \
97 gpr_log(GPR_ERROR, "assertion failed: %s", #x); \
103 #define GPR_DEBUG_ASSERT(x) GPR_ASSERT(x)
105 #define GPR_DEBUG_ASSERT(x)
GPRAPI void gpr_log_message(const char *file, int line, gpr_log_severity severity, const char *message)
Definition: log.cc:57
void(* gpr_log_func)(gpr_log_func_args *args)
Definition: log.h:86
GPRAPI void GPRAPI int gpr_should_log(gpr_log_severity severity)
Definition: log.cc:50
GPRAPI void gpr_log_verbosity_init(void)
Definition: log.cc:77
GPRAPI void gpr_log(const char *file, int line, gpr_log_severity severity, const char *format,...) GPR_PRINT_FORMAT_CHECK(4
Log a message.
GPRAPI void gpr_set_log_function(gpr_log_func func)
Definition: log.cc:96
GPRAPI const char * gpr_log_severity_string(gpr_log_severity severity)
Returns a string representation of the log severity.
Definition: log.cc:38
GPRAPI void gpr_set_log_verbosity(gpr_log_severity min_severity_to_print)
Set global log verbosity.
Definition: log.cc:72
gpr_log_severity
GPR log API.
Definition: log.h:43
@ GPR_LOG_SEVERITY_ERROR
Definition: log.h:46
@ GPR_LOG_SEVERITY_INFO
Definition: log.h:45
@ GPR_LOG_SEVERITY_DEBUG
Definition: log.h:44
Log overrides: applications can use this API to intercept logging calls and use their own implementat...
Definition: log.h:77
const char * file
Definition: log.h:78
const char * message
Definition: log.h:81
int line
Definition: log.h:79
gpr_log_severity severity
Definition: log.h:80