1 /* libundertow - undertow-logging.h
2 * Copyright (C) 2008 Michael Frank <msfrank@syntaxjockey.com>
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 3 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the
16 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
17 * Boston, MA 02111-1307, USA.
20 /**\file undertow-logging.h */
22 #ifndef LIBUNDERTOW_LOGGING_H
23 #define LIBUNDERTOW_LOGGING_H
31 /** Mirage log severity */
33 LUT_LOG_ERROR
, /**< A serious error occured */
34 LUT_LOG_WARNING
, /**< An problem occured which the user should be notified about */
35 LUT_LOG_INFO
, /**< Information which may be useful for the user when troubleshooting */
36 LUT_LOG_DEBUG
/**< Information which may be useful for the developer when troubleshooting */
39 /** Function prototype for the callback passed to lut_set_logging_funct() */
40 typedef void (*lut_logging_funct
)(lut_log_severity
, const char *);
42 lut_logging_funct
lut_get_logging_funct (void);
43 void lut_set_logging_funct (lut_logging_funct f
);
45 void lut_log (lut_log_severity s
, const char *fmt
, ...);
46 void lut_logv (lut_log_severity s
, const char *fmt
, va_list ap
);
47 void lut_log_error (const char *fmt
, ...);
48 void lut_log_warning (const char *fmt
, ...);
49 void lut_log_info (const char *fmt
, ...);
50 void lut_log_debug (const char *fmt
, ...);