18 #ifndef _LOG4CXX_HELPERS_SOCKET_H
19 #define _LOG4CXX_HELPERS_SOCKET_H
24 #if 15 < LOG4CXX_ABI_VERSION
25 #define LOG4CXX_16_CONST const
27 #define LOG4CXX_16_CONST
49 LOG4CXX_DECLARE_PRIVATE_MEMBER_PTR(SocketPrivate, m_priv)
50 Socket(LOG4CXX_PRIVATE_PTR(SocketPrivate) priv);
62 #if 15 < LOG4CXX_ABI_VERSION
68 virtual void setNonBlocking(
bool newValue) = 0;
71 virtual void open() = 0;
74 virtual bool is_open() = 0;
91 #if LOG4CXX_ABI_VERSION <= 15
92 static SocketUniquePtr
create(InetAddressPtr& address,
int port);
95 static SocketUniquePtr create(
const InetAddressPtr& address,
int port,
const LogString& concreteClassName = {});
106 #if 15 < LOG4CXX_ABI_VERSION
107 #define LOG4CXX_16_VIRTUAL_SPECIFIER override
109 #define LOG4CXX_16_VIRTUAL_SPECIFIER
An area of memory and a cursor into that memory.
Definition: bytebuffer.h:41
base class for java-like objects.
Definition: object.h:102
Abstract base class for an outgoing socket connection.
Definition: socket.h:47
int getPort() const
Returns the value of this socket's port field.
void setAttributes(const InetAddressPtr &newAddress, int newPort)
Use newAddress and newPort as the destination.
static SocketUniquePtr create(LOG4CXX_16_CONST InetAddressPtr &address, int port, const LogString &concreteClassName)
static SocketUniquePtr create(InetAddressPtr &address, int port)
Create a concrete instance of this class.
virtual void close()=0
Close this socket.
InetAddressPtr getInetAddress() const
Returns the value of this socket's address field.
LOG4CXX_UNIQUE_PTR_DEF(Socket)
std::basic_string< logchar > LogString
Definition: logstring.h:60
#define LOG4CXX_CAST_ENTRY(Interface)
Definition: object.h:154
#define DECLARE_ABSTRACT_LOG4CXX_OBJECT(object)
Definition: object.h:37
#define END_LOG4CXX_CAST_MAP()
Definition: object.h:148
#define BEGIN_LOG4CXX_CAST_MAP()
Definition: object.h:142
#define LOG4CXX_16_CONST
Definition: socket.h:27