log4shib::Appender(3)
β¨ log4shib::Appender β¨
okay bestie, this is the log4shib::Appender(3) page from the Library Functions Manual. it's giving βinterface you implement when you want your own strategy for printing log statements,β and we're gonna go through every single member function like it's a group-chat recap. no cap. π
πΈ NAME πΈ
log4shib::Appender β implement this interface for your own strategies for printing log statements. that's the whole point, bestie π
β¨ SYNOPSIS β¨
#include <Appender.hh>
Inherited by log4shib::AppenderSkeleton. π¦
π Public Member Functions π
virtual ~Appender ()β Destructor for Appender. πvirtual void doAppend (const LoggingEvent &event)=0β Log in Appender specific way. πvirtual bool reopen ()=0β Reopens the output destination of this Appender, e.g. (the synopsis literally stops ate.g.β the full sentence is down below, iykyk π)virtual void close ()=0β Release any resources allocated within the appender such as file handles, network connections, etc. πvirtual bool requiresLayout () const =0β Check if the appender uses a layout. πvirtual void setLayout (Layout *layout)=0β Set the Layout for this appender. πΌοΈconst std::string & getName () constβ Get the name of this appender. π·οΈvirtual void setThreshold (Priority::Value priority)=0β Set the threshold priority of this Appender. πvirtual Priority::Value getThreshold ()=0β Get the threshold priority of this Appender. πvirtual void setFilter (Filter *filter)=0β Set a Filter for this appender. π§Ήvirtual Filter * getFilter ()=0β Get the Filter for this appender. π
π Static Public Member Functions π
static Appender * getAppender (const std::string &name)β Get a pointer to an exitsing Appender. (their spelling, not mine π)static bool reopenAll ()β Callreopen()on all existing Appenders. πstatic void closeAll ()β Callreopen()on all existing Appenders. (yes, the closeAll description saysreopen()too β that's what the page says π)
π Protected Member Functions π
Appender (const std::string &name)β Constructor for Appender. π±
π Detailed Description π
Implement this interface for your own strategies for printing log statements. that's the assignment, bestie β make it yours. π
π§ Constructor & Destructor Documentation π§
π« log4shib::Appender::Appender (const std::string & name) [protected] π«
Constructor for Appender. Will only be used in getAppender() (and in derived classes of course).
Parameters
nameβ The name of this Appender.
π log4shib::Appender::~Appender () [virtual] π
Destructor for Appender.
π₯ Member Function Documentation π₯
π¦ virtual void log4shib::Appender::close () [pure virtual] π¦
Release any resources allocated within the appender such as file handles, network connections, etc.
Implemented in: log4shib::AbortAppender, log4shib::AppenderSkeleton, log4shib::FileAppender, log4shib::IdsaAppender, log4shib::NTEventLogAppender, log4shib::OstreamAppender, log4shib::RemoteSyslogAppender, log4shib::StringQueueAppender, log4shib::SyslogAppender, and log4shib::Win32DebugAppender.
πΈ void log4shib::Appender::closeAll () [static] πΈ
Call reopen() on all existing Appenders.
Returns
trueif all Appenders returnedtrueon theirreopen()call.
π virtual void log4shib::Appender::doAppend (const LoggingEvent & event) [pure virtual] π
Log in Appender specific way.
Parameters
eventβ TheLoggingEventto log.
Implemented in: log4shib::AppenderSkeleton.
π«Ά Appender * log4shib::Appender::getAppender (const std::string & name) [static] π«Ά
Get a pointer to an exitsing Appender. (yes, βexitsingβ is the original spelling, bestie π)
Parameters
nameβ The name of the Appender to return.
Returns
- a pointer to an existing Appender, or
NULLif no appender with the specfied name exists. (again: βspecfiedβ is their spelling π)
π
virtual Filter * log4shib::Appender::getFilter () [pure virtual] π
Get the Filter for this appender.
Returns
- the filter, or
NULLif no filter has been set.
Implemented in: log4shib::AppenderSkeleton.
β const std::string & log4shib::Appender::getName () const [inline] β
Get the name of this appender. The name identifies the appender.
Returns
- the name of the appender.
π virtual Priority::Value log4shib::Appender::getThreshold () [pure virtual] π
Get the threshold priority of this Appender.
Returns
- the threshold
Implemented in: log4shib::AppenderSkeleton.
π§ virtual bool log4shib::Appender::reopen () [pure virtual] π§
Reopens the output destination of this Appender, e.g. the logfile or TCP socket.
Returns
falseif an error occured during reopening,trueotherwise.
Implemented in: log4shib::AbortAppender, log4shib::AppenderSkeleton, log4shib::FileAppender, log4shib::IdsaAppender, log4shib::NTEventLogAppender, log4shib::OstreamAppender, log4shib::RemoteSyslogAppender, log4shib::StringQueueAppender, and log4shib::SyslogAppender.
π bool log4shib::Appender::reopenAll () [static] π
Call reopen() on all existing Appenders.
Returns
trueif all Appenders returnedtrueon theirreopen()call.
π¦ virtual bool log4shib::Appender::requiresLayout () const [pure virtual] π¦
Check if the appender uses a layout.
Returns
trueif the appender implementation requires a layout.
Implemented in: log4shib::AbortAppender, log4shib::AppenderSkeleton, log4shib::IdsaAppender, and log4shib::LayoutAppender.
π virtual void log4shib::Appender::setFilter (Filter * filter) [pure virtual] π
Set a Filter for this appender.
Implemented in: log4shib::AppenderSkeleton.
π§ virtual void log4shib::Appender::setLayout (Layout * layout) [pure virtual] π§
Set the Layout for this appender.
Parameters
layoutβ The layout to use.
Implemented in: log4shib::AbortAppender, log4shib::AppenderSkeleton, log4shib::IdsaAppender, and log4shib::LayoutAppender.
π virtual void log4shib::Appender::setThreshold (Priority::Value priority) [pure virtual] π
Set the threshold priority of this Appender. The Appender will not append LoggingEvents with a priority lower than the threshold. Use Priority::NOTSET to disable threshold checking.
Parameters
priorityβ The priority to set.
Implemented in: log4shib::AppenderSkeleton.
π Author π
Generated automatically by Doxygen for log4shib from the source code. so no human author to tag β Doxygen ate and left no crumbs π
sign-off bestie: this page is from log4shib Version 2.0.1 and its manual name is log4shib::Appender(3). the footer doesn't print a date here, so we're not inventing one β mwah ππ«Ά
π¦ where this page comes from
- opensuse-leap 16.0: liblog4shib-devel 2.0.1-160000.3.2 Β· LGPL-2.1-only
- opensuse-leap 16.0: liblog4shib-devel 2.0.1-160000.3.2 Β· LGPL-2.1-only
- opensuse-leap 16.0: liblog4shib-devel 2.0.1-160000.3.2 Β· LGPL-2.1-only
- opensuse-leap 16.0: liblog4shib-devel 2.0.1-160000.3.2 Β· LGPL-2.1-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms