24#ifndef LOG4CPLUS_FILE_APPENDER_HEADER_
25#define LOG4CPLUS_FILE_APPENDER_HEADER_
29#if defined (LOG4CPLUS_HAVE_PRAGMA_ONCE)
124 virtual std::locale
imbue(std::locale
const& loc);
132 std::ios_base::openmode mode = std::ios_base::trunc,
136 std::ios_base::openmode mode = std::ios_base::trunc);
142 virtual void open(std::ios_base::openmode mode);
178 std::unique_ptr<log4cplus::tchar[]>
buffer;
205 std::ios_base::openmode mode = std::ios_base::trunc,
209 std::ios_base::openmode mode = std::ios_base::trunc);
402 void open(std::ios_base::openmode mode);
virtual ~DailyRollingFileAppender()
void rollover(bool alreadyLocked=false)
DailyRollingFileAppender(const log4cplus::helpers::Properties &properties)
virtual void close()
Release any resources allocated within the appender such as file handles, network connections,...
log4cplus::tstring getFilename(const log4cplus::helpers::Time &t) const
DailyRollingFileAppender(const log4cplus::tstring &filename, DailyRollingFileSchedule schedule=DAILY, bool immediateFlush=true, int maxBackupIndex=10, bool createDirs=false, bool rollOnClose=true, const log4cplus::tstring &datePattern=log4cplus::tstring())
log4cplus::tstring datePattern
virtual void append(const spi::InternalLoggingEvent &event)
Subclasses of Appender should implement this method to perform actual logging.
log4cplus::helpers::Time calculateNextRolloverTime(const log4cplus::helpers::Time &t) const
DailyRollingFileSchedule schedule
log4cplus::helpers::Time nextRolloverTime
log4cplus::tstring scheduledFilename
virtual void append(const spi::InternalLoggingEvent &event)
Subclasses of Appender should implement this method to perform actual logging.
log4cplus::helpers::Time reopen_time
bool immediateFlush
Immediate flush means that the underlying writer or output stream will be flushed at the end of each ...
log4cplus::tstring lockFileName
bool createDirs
When this variable is true, FileAppender will try to create missing directories in path leading to lo...
virtual std::locale imbue(std::locale const &loc)
std::ios_base::openmode fileOpenMode
log4cplus::tstring filename
virtual void open(std::ios_base::openmode mode)
int reopenDelay
When any append operation fails, reopenDelay says for how many seconds the next attempt to re-open th...
log4cplus::tstring localeName
FileAppenderBase(const log4cplus::helpers::Properties &properties, std::ios_base::openmode mode=std::ios_base::trunc)
virtual void close()
Release any resources allocated within the appender such as file handles, network connections,...
std::unique_ptr< log4cplus::tchar[]> buffer
FileAppenderBase(const log4cplus::tstring &filename, std::ios_base::openmode mode=std::ios_base::trunc, bool immediateFlush=true, bool createDirs=false)
virtual std::locale getloc() const
FileAppender(const log4cplus::tstring &filename, std::ios_base::openmode mode=std::ios_base::trunc, bool immediateFlush=true, bool createDirs=false)
FileAppender(const log4cplus::helpers::Properties &properties, std::ios_base::openmode mode=std::ios_base::trunc)
RollingFileAppender(const log4cplus::helpers::Properties &properties)
void rollover(bool alreadyLocked=false)
RollingFileAppender(const log4cplus::tstring &filename, long maxFileSize=10 *1024 *1024, int maxBackupIndex=1, bool immediateFlush=true, bool createDirs=false)
virtual void append(const spi::InternalLoggingEvent &event)
Subclasses of Appender should implement this method to perform actual logging.
virtual ~RollingFileAppender()
TimeBasedRollingFileAppender(const helpers::Properties &properties)
log4cplus::helpers::Time lastHeartBeat
void close()
Release any resources allocated within the appender such as file handles, network connections,...
TimeBasedRollingFileAppender(const tstring &filename=LOG4CPLUS_TEXT(""), const tstring &filenamePattern=LOG4CPLUS_TEXT("%d.log"), int maxHistory=10, bool cleanHistoryOnStart=false, bool immediateFlush=true, bool createDirs=false, bool rollOnClose=true)
void append(const spi::InternalLoggingEvent &event)
Subclasses of Appender should implement this method to perform actual logging.
log4cplus::helpers::Time nextRolloverTime
tstring scheduledFilename
DailyRollingFileSchedule schedule
void open(std::ios_base::openmode mode)
~TimeBasedRollingFileAppender()
void clean(helpers::Time time)
helpers::Time calculateNextRolloverTime(const helpers::Time &t) const
void rollover(bool alreadyLocked=false)
helpers::Time::duration getRolloverPeriodDuration() const
The internal representation of logging events.
#define LOG4CPLUS_TEXT(STRING)
#define LOG4CPLUS_PRIVATE
chrono::time_point< Clock, Duration > Time
helpers::SharedObjectPtr< RollingFileAppender > SharedRollingFileAppenderPtr
helpers::SharedObjectPtr< DailyRollingFileAppender > SharedDailyRollingFileAppenderPtr
std::basic_ofstream< tchar > tofstream
helpers::SharedObjectPtr< TimeBasedRollingFileAppender > SharedTimeBasedRollingFileAppenderPtr
std::basic_string< tchar > tstring
helpers::SharedObjectPtr< FileAppender > SharedFileAppenderPtr