|
OrocosComponentLibrary
2.8.3
|
Appender supporting generations of log files. More...
#include <GenerationalFileAppender.hpp>
Public Member Functions | |
| GenerationalFileAppender (std::string name) | |
| virtual bool | configureLayout () |
| Optionally create a layout according to layoutName and layoutPattern. More... | |
| virtual bool | startHook () |
| ensure port is connected before we start More... | |
| virtual void | stopHook () |
| Drain the buffer. | |
| virtual void | drainBuffer () |
| Process all remaining events in buffer. | |
Protected Member Functions | |
| virtual bool | configureHook () |
| Create log4cpp appender. | |
| virtual void | updateHook () |
| Process at most maxEventsPerCycle event. | |
| virtual void | cleanupHook () |
| Destroy appender. | |
| void | advanceGeneration () |
| Advance to the next logfile generation. | |
| virtual void | processEvents (int n) |
| Process up n events. More... | |
Protected Attributes | |
| RTT::Operation< void(void)> | advanceGeneration_op |
| RTT::Property< std::string > | filename_prop |
| Name of file to append to. | |
| RTT::Property< int > | maxEventsPerCycle_prop |
| Property to set maximum number of log events to pop per cycle. | |
| int | maxEventsPerCycle |
| Maximum number of log events to pop per cycle. More... | |
| RTT::InputPort< OCL::logging::LoggingEvent > | log_port |
| Port we receive logging events on Initially unconnected. More... | |
| log4cpp::Appender * | appender |
| Appender created by derived class. | |
| RTT::Property< std::string > | layoutName_prop |
| Layout name (e.g. "simple", "basic", "pattern") | |
| RTT::Property< std::string > | layoutPattern_prop |
| Layout conversion pattern (for those layouts that use a pattern) | |
| unsigned int | countMaxPopped |
Appender supporting generations of log files.
Each new generation is logged to a new file
Definition at line 14 of file GenerationalFileAppender.hpp.
|
virtualinherited |
Optionally create a layout according to layoutName and layoutPattern.
Definition at line 29 of file Appender.cpp.
|
protectedvirtualinherited |
Process up n events.
| n | if 0 ==n then process events until buffer is empty, otherwise process at most n events |
Definition at line 104 of file Appender.cpp.
References LoggingEvent::toLog4cpp().
|
virtualinherited |
ensure port is connected before we start
Definition at line 69 of file Appender.cpp.
|
protected |
Definition at line 28 of file GenerationalFileAppender.hpp.
|
protectedinherited |
Port we receive logging events on Initially unconnected.
The logging service connects appenders.
Definition at line 47 of file Appender.hpp.
Referenced by Category::callAppenders(), and Category::connectToLogPort().
|
protected |
Maximum number of log events to pop per cycle.
Defaults to 1.
A value of 0 indicates to not limit the number of events per cycle. With enough event production, this could lead to thread starvation!
Definition at line 48 of file GenerationalFileAppender.hpp.
1.8.11