/builddir/build/BUILD/qpid-proton-0.10/proton-c/include/proton/log.h File Reference

Control log messages that are not associated with a transport. More...

#include <proton/import_export.h>
#include <proton/type_compat.h>

Go to the source code of this file.

Typedefs

typedef void(* pn_logger_t )(const char *message)
 Callback for customized logging.

Functions

PN_EXTERN void pn_log_enable (bool enabled)
 Enable/disable global logging.
PN_EXTERN void pn_log_logger (pn_logger_t logger)
 Set the logger.

Detailed Description

Control log messages that are not associated with a transport.

See pn_transport_trace for transport-related logging.


Typedef Documentation

typedef void(* pn_logger_t)(const char *message)

Callback for customized logging.


Function Documentation

PN_EXTERN void pn_log_enable ( bool  enabled  ) 

Enable/disable global logging.

By default, logging is enabled by envionment variable PN_TRACE_LOG. Calling this function overrides the environment setting.

PN_EXTERN void pn_log_logger ( pn_logger_t  logger  ) 

Set the logger.

By default a logger that prints to stderr is installed.

Parameters:
logger is called with each log messsage if logging is enabled. Passing 0 disables logging regardless of pn_log_enable() or environment settings.
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines

Generated on 1 Oct 2015 for proton by  doxygen 1.6.1