On 2009-06-23 23:00, Assaf Lavie wrote:
1. I find it very useful to implement a simple stack class that uses RAII to
manage the NDC stack. In fact, I find it odd that log4cxx doesn't come with
one built-in..2.
I just use the NDC class and "push" via the constructor. It "pops" when the
object is deconstructed [0]. This fits my expectations of RAII[1].
[0] http://wiki.apache.org/logging-log4cxx/NestedDiagnosticContexts
[1] http://www.parashift.com/c++-faq-lite/big-picture.html#faq-6.18
--
Jacob Anawalt
Gecko Software, Inc.
janaw...@geckosoftware.com
435-752-8026