|
Apache Log4cxx
Version 1.5.0
|
Go to the documentation of this file.
18 #ifndef _LOG4CXX_NET_SOCKET_APPENDER_SKELETON_H
19 #define _LOG4CXX_NET_SOCKET_APPENDER_SKELETON_H
24 #include <condition_variable>
38 struct SocketAppenderSkeletonPriv;
147 virtual void setSocket(LOG4CXX_NS::helpers::SocketPtr& socket, LOG4CXX_NS::helpers::Pool& p) = 0;
149 virtual void cleanUp(LOG4CXX_NS::helpers::Pool& p) = 0;
156 void connect(LOG4CXX_NS::helpers::Pool& p);
176 #endif // _LOG4CXX_NET_SOCKET_APPENDER_SKELETON_H
void setLocationInfo(bool locationInfo1)
The LocationInfo option takes a boolean value.
void setPort(int port1)
The Port option takes a positive integer representing the port where the server is waiting for connec...
std::basic_string< logchar > LogString
Definition: logstring.h:60
virtual int getDefaultPort() const =0
void setOption(const LogString &option, const LogString &value) override
Set option to value.
SocketAppenderSkeleton(helpers::InetAddressPtr address, int port, int reconnectionDelay)
Connects to remote server at address and port.
int getReconnectionDelay() const
Returns value of the ReconnectionDelay option.
void setReconnectionDelay(int reconnectionDelay1)
The ReconnectionDelay option takes a positive integer representing the number of milliseconds to wait...
virtual int getDefaultDelay() const =0
void setRemoteHost(const LogString &host)
The RemoteHost option takes a string value which should be the host name of the server where a Apache...
const LogString & getRemoteHost() const
Returns value of the RemoteHost option.
Abstract base class for SocketAppender and XMLSocketAppender.
Definition: socketappenderskeleton.h:36
bool getLocationInfo() const
Returns value of the LocationInfo option.
virtual void setSocket(log4cxx::helpers::SocketPtr &socket, log4cxx::helpers::Pool &p)=0
~SocketAppenderSkeleton()
int getPort() const
Returns value of the Port option.
Implementation base class for all appenders.
Definition: appenderskeleton.h:41
void activateOptions(helpers::Pool &p) override
Activate the options that were previously set with calls to option setters.
SocketAppenderSkeleton(const LogString &host, int port, int reconnectionDelay)
Connects to remote server at host and port.
SocketAppenderSkeleton(int defaultPort, int reconnectionDelay)
void close() override
Release any resources allocated within the appender such as file handles, network connections,...
SocketAppenderSkeleton(std::unique_ptr< SocketAppenderSkeletonPriv > priv)
virtual void cleanUp(log4cxx::helpers::Pool &p)=0
bool requiresLayout() const override
This appender does not use a layout.
Definition: socketappenderskeleton.h:69