#include <TraceObject.h>
Inheritance diagram for ClearSilver::TraceObject:

Public Member Functions | |
| TraceObject (bool, const std::string &) | |
| TraceObject (bool, const std::string &, const std::string &) | |
| TraceObject (const TraceObject &) | |
| virtual | ~TraceObject () throw () |
| TraceObject & | operator= (const TraceObject &) |
| void | swap (TraceObject &) throw () |
Static Public Member Functions | |
| static bool & | log_messages () |
| static bool & | stream_messages () |
This class provides a simple means of logging the lifetime of objects to syslog(3). This class implements logging actions for each of the fundamental methods that affect object lifetime: creation, destruction, assignment, and swapping. Classes derived from this will trigger logging messages when they themselves are created, destroyed, etc. This can simplify the debugging process for situations in which object lifetime must be traced.
Because this introduces potentially undesirable overhead into any objects derived from TraceObject, it is possible at compile time to replace the class with an empty class that does no logging but has no overhead. This is controlled by the HAVE_OBJECT_TRACING preprocessor macro, which is controlled by the --enable-object-tracing and --disable-object-tracing configure options. Note that if object tracing is controlled by some other means, e.g., by controlling the definition of HAVE_OBJECT_TRACING outside the provided configuration mechamism, care must be taken to ensure that all uses of TraceObject.h are consistent. Otherwise, subtle bugs will occur as a result of disagreement about class definitions.
Definition at line 105 of file TraceObject.h.
1.4.5