Appends log events to NT EventLog. More...
Inherits log4cxx::AppenderSkeleton.
Classes | |
class | ClazzNTEventLogAppender |
Public Member Functions | |
virtual const helpers::Class & | getClass () const |
const void * | cast (const helpers::Class &clazz) const |
bool | instanceof (const helpers::Class &clazz) const |
NTEventLogAppender () | |
NTEventLogAppender (const LogString &server, const LogString &log, const LogString &source, const LayoutPtr &layout) | |
virtual | ~NTEventLogAppender () |
virtual void | activateOptions (log4cxx::helpers::Pool &p) |
Derived appenders should override this method if option structure requires it. | |
virtual void | close () |
Release any resources allocated within the appender such as file handles, network connections, etc. | |
virtual void | setOption (const LogString &option, const LogString &value) |
Set option to value . | |
bool | requiresLayout () const |
The SocketAppender does not use a layout. | |
void | setSource (const LogString &source) |
const LogString & | getSource () const |
void | setLog (const LogString &log) |
const LogString & | getLog () const |
void | setServer (const LogString &server) |
const LogString & | getServer () const |
Static Public Member Functions | |
static const helpers::Class & | getStaticClass () |
static const log4cxx::helpers::ClassRegistration & | registerClass () |
Protected Types | |
typedef void | SID |
typedef void * | HANDLE |
Protected Member Functions | |
virtual void | append (const spi::LoggingEventPtr &event, log4cxx::helpers::Pool &p) |
Subclasses of AppenderSkeleton should implement this method to perform actual logging. | |
void | addRegistryInfo () |
Static Protected Member Functions | |
static unsigned short | getEventType (const spi::LoggingEventPtr &event) |
static unsigned short | getEventCategory (const spi::LoggingEventPtr &event) |
static LogString | getErrorString (const LogString &function) |
Protected Attributes | |
LogString | server |
LogString | log |
LogString | source |
HANDLE | hEventLog |
SID * | pCurrentUserSID |
Appends log events to NT EventLog.
typedef void* HANDLE [protected] |
typedef void SID [protected] |
NTEventLogAppender | ( | const LogString & | server, | |
const LogString & | log, | |||
const LogString & | source, | |||
const LayoutPtr & | layout | |||
) |
virtual ~NTEventLogAppender | ( | ) | [virtual] |
virtual void activateOptions | ( | log4cxx::helpers::Pool & | ) | [virtual] |
Derived appenders should override this method if option structure requires it.
Reimplemented from AppenderSkeleton.
void addRegistryInfo | ( | ) | [protected] |
virtual void append | ( | const spi::LoggingEventPtr & | event, | |
log4cxx::helpers::Pool & | p | |||
) | [protected, virtual] |
Subclasses of AppenderSkeleton
should implement this method to perform actual logging.
See also AppenderSkeleton::doAppend method.
Implements AppenderSkeleton.
const void* cast | ( | const helpers::Class & | clazz | ) | const [inline, virtual] |
Implements Object.
virtual void close | ( | ) | [virtual] |
Release any resources allocated within the appender such as file handles, network connections, etc.
It is a programming error to append to a closed appender.
Implements Appender.
virtual const helpers::Class& getClass | ( | ) | const [virtual] |
Reimplemented from Object.
static unsigned short getEventCategory | ( | const spi::LoggingEventPtr & | event | ) | [static, protected] |
static unsigned short getEventType | ( | const spi::LoggingEventPtr & | event | ) | [static, protected] |
const LogString& getLog | ( | ) | const [inline] |
const LogString& getServer | ( | ) | const [inline] |
const LogString& getSource | ( | ) | const [inline] |
static const helpers::Class& getStaticClass | ( | ) | [static] |
Reimplemented from Object.
bool instanceof | ( | const helpers::Class & | clazz | ) | const [inline, virtual] |
Implements Object.
static const log4cxx::helpers::ClassRegistration& registerClass | ( | ) | [static] |
Reimplemented from Object.
bool requiresLayout | ( | ) | const [inline, virtual] |
void setLog | ( | const LogString & | log | ) | [inline] |
Set option
to value
.
The handling of each option depends on the OptionHandler instance. Some options may become active immediately whereas other may be activated only when activateOptions is called.
Reimplemented from AppenderSkeleton.
void setServer | ( | const LogString & | server | ) | [inline] |
void setSource | ( | const LogString & | source | ) | [inline] |
SID* pCurrentUserSID [protected] |