|
Apache Log4cxx
Version 2.0.0
|
A RollingPolicy is responsible for performing the rolling over of the active log file.
More...
#include <rollingpolicy.h>
Public Member Functions | |
| virtual | ~RollingPolicy () |
| virtual RolloverDescriptionPtr | initialize (const LogString ¤tActiveFile, bool append)=0 |
| Initialize the policy and return any initial actions for rolling file appender. | |
| RolloverDescriptionPtr | initialize (const LogString ¤tActiveFile, bool append, helpers::Pool &pool) |
| virtual RolloverDescriptionPtr | rollover (const LogString ¤tActiveFile, bool append)=0 |
| Prepare for a rollover. | |
| RolloverDescriptionPtr | rollover (const LogString ¤tActiveFile, bool append, helpers::Pool &pool) |
| Public Member Functions inherited from log4cxx::spi::OptionHandler | |
| virtual | ~OptionHandler () |
| virtual void | activateOptions ()=0 |
| Activate the options that were previously set with calls to option setters. | |
| void | activateOptions (helpers::Pool &) |
| virtual void | setOption (const LogString &option, const LogString &value) |
Set option to value. | |
| Public Member Functions inherited from log4cxx::helpers::Object | |
| virtual | ~Object () |
| virtual const helpers::Class & | getClass () const =0 |
| virtual bool | instanceof (const Class &clazz) const =0 |
| virtual const void * | cast (const Class &clazz) const =0 |
A RollingPolicy is responsible for performing the rolling over of the active log file.
The RollingPolicy is also responsible for providing the active log file, that is the live file where logging output will be directed.
|
inlinevirtual |
|
pure virtual |
Initialize the policy and return any initial actions for rolling file appender.
| currentActiveFile | current value of RollingFileAppender.getFile(). |
| append | current value of RollingFileAppender.getAppend(). |
Implemented in log4cxx::rolling::FixedWindowRollingPolicy, and log4cxx::rolling::TimeBasedRollingPolicy.
| RolloverDescriptionPtr log4cxx::rolling::RollingPolicy::initialize | ( | const LogString & | currentActiveFile, |
| bool | append, | ||
| helpers::Pool & | pool ) |
|
pure virtual |
Prepare for a rollover.
This method is called prior to closing the active log file, performs any necessary preliminary actions and describes actions needed after close of current log file.
| currentActiveFile | file name for current active log file. |
| append | current value of the parent FileAppender.getAppend(). |
Implemented in log4cxx::rolling::FixedWindowRollingPolicy, and log4cxx::rolling::TimeBasedRollingPolicy.
| RolloverDescriptionPtr log4cxx::rolling::RollingPolicy::rollover | ( | const LogString & | currentActiveFile, |
| bool | append, | ||
| helpers::Pool & | pool ) |