9 #ifndef IMPBASE_CREATE_LOG_CONTEXT_H
10 #define IMPBASE_CREATE_LOG_CONTEXT_H
12 #include <IMP/base/base_config.h>
17 #if IMP_BASE_HAS_LOG4CXX
18 #include <log4cxx/ndc.h>
19 #include <boost/scoped_ptr.hpp>
22 IMPBASE_BEGIN_NAMESPACE
49 #if IMP_BASE_HAS_LOG4CXX
51 boost::scoped_ptr<log4cxx::NDC> ndc1_;
55 : ndc0_(object->get_quoted_name_c_string()),
56 ndc1_(
new log4cxx::NDC(fname)) {}
67 push_log_context(name_.c_str(), object);
70 (
const char* fname,
const Object*
object =
nullptr), ,
71 push_log_context(fname,
object), pop_log_context(), );
#define IMP_UNUSED(variable)
#define IMP_SHOWABLE_INLINE(Name, how_to_show)
Declare the methods needed by an object that can be printed.
Provide a nullptr keyword analog.
Various general useful macros for IMP.
Common base class for heavy weight IMP objects.
#define IMP_RAII(Name, args, Initialize, Set, Reset, Show)
Declares RAII-style methods in a class.
Logging and error reporting support.
A shared base class to help in debugging and things.
Create a new log context.