tdesocketdevice.cpp
396 static int do_read_common(int sockfd, char *data, TQ_ULONG maxlen, TDESocketAddress* from, ssize_t &retval, bool peek = false)
443 TQT_TQIO_LONG TDESocketDevice::tqreadBlock(char *data, TQT_TQIO_ULONG maxlen, TDESocketAddress &from)
511 TQT_TQIO_LONG TDESocketDevice::tqwriteBlock(const char *data, TQT_TQIO_ULONG len, const TDESocketAddress& to)
TQSocketNotifier * readNotifier() const
Returns a socket notifier for input on this socket.
Definition: tdesocketdevice.cpp:614
virtual void setSocketDevice(TDESocketDevice *device)
Sets the socket implementation to be used on this socket.
Definition: tdesocketbase.cpp:136
virtual TDESocketAddress externalAddress() const
Returns this socket's externally visible local address.
Definition: tdesocketdevice.cpp:607
static void addNewImpl(TDESocketDeviceFactoryBase *factory, int capabilities)
Adds a factory of TDESocketDevice objects to the list, along with its capabilities flag...
Definition: tdesocketdevice.cpp:884
virtual TQSocketNotifier * createNotifier(TQSocketNotifier::Type type) const
Creates a socket notifier of the given type.
Definition: tdesocketdevice.cpp:796
TQSocketNotifier * exceptionNotifier() const
Returns a socket notifier for exceptional events on this socket.
Definition: tdesocketdevice.cpp:650
virtual TDESocketDevice * accept()
Accepts a new incoming connection.
Definition: tdesocketdevice.cpp:309
virtual TQ_LONG waitForMore(int msecs, bool *timeout=0L)
Returns the number of bytes available for reading without blocking.
Definition: tdesocketdevice.cpp:384
TQMutex * mutex() const
Returns the internal mutex for this class.
Definition: tdesocketbase.cpp:278
void resetError()
Resets the socket error code and the I/O Device's status.
Definition: tdesocketbase.cpp:315
virtual bool create(int family, int type, int protocol)
Creates a socket but don't connect or bind anywhere.
Definition: tdesocketdevice.cpp:201
TQSocketNotifier * writeNotifier() const
Returns a socket notifier for output on this socket.
Definition: tdesocketdevice.cpp:632
virtual TQT_TQIO_LONG tqwriteBlock(const char *data, TQT_TQIO_ULONG len)
Writes data to the socket.
Definition: tdesocketdevice.cpp:506
int protocol() const
Retrieves the protocol associated with this entry.
Definition: kresolver.cpp:178
TDESocketAddress address() const
Retrieves the socket address associated with this entry.
Definition: kresolver.cpp:142
A namespace to store all networking-related (socket) classes.
Definition: kbufferedsocket.h:36
TDESocketAddress & setLength(TQ_UINT16 len)
Sets the length of this socket structure.
Definition: tdesocketaddress.cpp:492
void setError(int status, SocketError error)
Sets the socket's error code and the I/O Device's status.
Definition: tdesocketbase.cpp:309
static TDESocketDeviceFactoryBase * setDefaultImpl(TDESocketDeviceFactoryBase *factory)
Sets the default TDESocketDevice implementation to use and return the old factory.
Definition: tdesocketdevice.cpp:876
TQ_UINT16 length() const
Retrieves the length of the socket address structure.
Definition: kresolver.cpp:148
static TDESocketDevice * createDefault(TDESocketBase *parent)
Creates a new default TDESocketDevice object given the parent object.
Definition: tdesocketdevice.cpp:844
const sockaddr * address() const
Returns the socket address structure, to be passed down to low level functions.
Definition: tdesocketaddress.cpp:461
virtual bool connect(const KResolverEntry &address)
Connect to a remote host.
Definition: tdesocketdevice.cpp:276
virtual TQT_TQIO_LONG tqreadBlock(char *data, TQT_TQIO_ULONG maxlen)
Reads data from this socket.
Definition: tdesocketdevice.cpp:422
virtual bool open(TQ_OpenMode mode)
Reimplementation from TQIODevice.
Definition: tdesocketdevice.cpp:174
virtual int socketOptions() const
Retrieves the socket options that have been set.
Definition: tdesocketbase.cpp:71
int socketType() const
Retrieves the socket type associated with this entry.
Definition: kresolver.cpp:172
virtual bool setSocketOptions(int opts)
This implementation sets the options on the socket.
Definition: tdesocketdevice.cpp:110
virtual bool bind(const KResolverEntry &address)
Binds this socket to the given address.
Definition: tdesocketdevice.cpp:232
virtual int capabilities() const
Returns the set of capabilities this socket class implements.
Definition: tdesocketdevice.h:134
int family() const
Retrieves the family associated with this socket address.
Definition: kresolver.cpp:154
virtual bool poll(bool *input, bool *output, bool *exception=0L, int timeout=-1, bool *timedout=0L)
Executes a poll in the socket, via select(2) or poll(2).
Definition: tdesocketdevice.cpp:668
virtual TQ_LONG peekBlock(char *data, TQ_ULONG maxlen)
Peeks data in the socket.
Definition: tdesocketdevice.cpp:464
virtual bool setSocketOptions(int opts)
Set the given socket options.
Definition: tdesocketbase.cpp:65
virtual bool listen(int backlog=5)
Puts this socket into listening mode.
Definition: tdesocketdevice.cpp:255
TQ_UINT16 length() const
Returns the length of this socket address structure.
Definition: tdesocketaddress.cpp:485
virtual TDESocketAddress & setFamily(int family)
Sets the family of this object.
Definition: tdesocketaddress.cpp:506
virtual TDESocketAddress peerAddress() const
Returns this socket's peer address.
Definition: tdesocketdevice.cpp:571
virtual TDESocketAddress localAddress() const
Returns this socket's local address.
Definition: tdesocketdevice.cpp:535