Public Member Functions | Static Public Attributes | Protected Member Functions | Protected Attributes | List of all members
log4cpp::DailyRollingFileAppender Class Reference

#include <DailyRollingFileAppender.hh>

Inheritance diagram for log4cpp::DailyRollingFileAppender:
Inheritance graph

Public Member Functions

 DailyRollingFileAppender (const std::string &name, const std::string &fileName, unsigned int maxDaysToKeep=maxDaysToKeepDefault, bool append=true, mode_t mode=00644)
virtual unsigned int getMaxDaysToKeep () const
virtual void rollOver ()
virtual void setMaxDaysToKeep (unsigned int maxDaysToKeep)
- Public Member Functions inherited from log4cpp::FileAppender
virtual void close ()
 FileAppender (const std::string &name, const std::string &fileName, bool append=true, mode_t mode=00644)
 FileAppender (const std::string &name, int fd)
virtual bool getAppend () const
virtual mode_t getMode () const
virtual bool reopen ()
virtual void setAppend (bool append)
virtual void setMode (mode_t mode)
virtual ~FileAppender ()
- Public Member Functions inherited from log4cpp::LayoutAppender
 LayoutAppender (const std::string &name)
virtual bool requiresLayout () const
virtual void setLayout (Layout *layout=NULL)
virtual ~LayoutAppender ()
- Public Member Functions inherited from log4cpp::AppenderSkeleton
virtual void doAppend (const LoggingEvent &event)
virtual FiltergetFilter ()
virtual Priority::Value getThreshold ()
virtual void setFilter (Filter *filter)
virtual void setThreshold (Priority::Value priority)
virtual ~AppenderSkeleton ()
- Public Member Functions inherited from log4cpp::Appender
const std::string & getName () const
virtual ~Appender ()

Static Public Attributes

static unsigned int maxDaysToKeepDefault = 30

Protected Member Functions

virtual void _append (const LoggingEvent &event)
- Protected Member Functions inherited from log4cpp::LayoutAppender
Layout_getLayout ()
- Protected Member Functions inherited from log4cpp::AppenderSkeleton
 AppenderSkeleton (const std::string &name)
- Protected Member Functions inherited from log4cpp::Appender
 Appender (const std::string &name)

Protected Attributes

struct tm _logsTime
unsigned int _maxDaysToKeep
- Protected Attributes inherited from log4cpp::FileAppender
int _fd
const std::string _fileName
int _flags
mode_t _mode

Additional Inherited Members

- Public Types inherited from log4cpp::LayoutAppender
typedef BasicLayout DefaultLayoutType
- Static Public Member Functions inherited from log4cpp::Appender
static void closeAll ()
static AppendergetAppender (const std::string &name)
static bool reopenAll ()

Detailed Description

DailyRollingFileAppender is a FileAppender that rolls over the logfile once the next day starts.


Definition at line 22 of file DailyRollingFileAppender.hh.

Constructor & Destructor Documentation

log4cpp::DailyRollingFileAppender::DailyRollingFileAppender ( const std::string &  name,
const std::string &  fileName,
unsigned int  maxDaysToKeep = maxDaysToKeepDefault,
bool  append = true,
mode_t  mode = 00644 

Definition at line 40 of file DailyRollingFileAppender.cpp.

Member Function Documentation

void log4cpp::DailyRollingFileAppender::_append ( const LoggingEvent event)

Log in Appender specific way. Subclasses of Appender should implement this method to perform actual logging.

eventThe LoggingEvent to log.

Reimplemented from log4cpp::FileAppender.

Definition at line 142 of file DailyRollingFileAppender.cpp.

unsigned int log4cpp::DailyRollingFileAppender::getMaxDaysToKeep ( ) const

Definition at line 69 of file DailyRollingFileAppender.cpp.

void log4cpp::DailyRollingFileAppender::rollOver ( )

Definition at line 73 of file DailyRollingFileAppender.cpp.

void log4cpp::DailyRollingFileAppender::setMaxDaysToKeep ( unsigned int  maxDaysToKeep)

Definition at line 65 of file DailyRollingFileAppender.cpp.

Member Data Documentation

struct tm log4cpp::DailyRollingFileAppender::_logsTime

Definition at line 41 of file DailyRollingFileAppender.hh.

unsigned int log4cpp::DailyRollingFileAppender::_maxDaysToKeep

Definition at line 39 of file DailyRollingFileAppender.hh.

unsigned int log4cpp::DailyRollingFileAppender::maxDaysToKeepDefault = 30

Definition at line 35 of file DailyRollingFileAppender.hh.

The documentation for this class was generated from the following files:

Author(s): Stephen Roderick, Bastiaan Bakker, Cedric Le Goater, Steve Ostlind, Marcel Harkema, Walter Stroebel, Glenn Scott and Tony Cheung
autogenerated on Sun Jun 23 2019 19:10:00