On Dec 13, 2004, at 11:12 PM, Prosenjit Sinha wrote:
Thanx Curt,
I have included <log4cxx/patternlayout.h> and it worked.Currently I
am facing a new problem.I was trying to access Ostream *os variable to get
the logging string.But I failed to get the string.I have explicitely set the
immediateFlush variable as FALSE.
As you said OStream *os will be removed very soon so is there any
other way by which I can get the logging string in a custom appender??
It has already been removed in the CVS and it is trivial to get the formatted logging message by overriding WriterAppender::subAppend(const LogString& msg, apr_pool_t* p) which gets the message after formatting but before encoding or writing to the destination.
I've committed the changes to the CVS to get early feedback on compilation problems with applications using log4cxx. log4cxx doesn't build on all the supported platforms or pass its self tests just at the moment but I expect at a subset of the appenders to be usable within a few days.
Also please tell me is there any way by which at run time we can block an appender which is attached to the Root Logger.
You will have to clarify your request. Block could mean several different things in this context.
