KDECore
k3socketbase.h
Go to the documentation of this file.
virtual bool disconnect()=0
Disconnects this socket from a connection, if possible.
virtual bool connect(const KResolverEntry &address, OpenMode mode=ReadWrite)=0
Connect to a remote host.
virtual qint64 readData(char *data, qint64 maxlen, KSocketAddress *from)=0
This is an overloaded member function, provided for convenience. It differs from the above function o...
virtual KSocketAddress localAddress() const =0
Returns this socket's local address.
virtual qint64 writeData(const char *data, qint64 len, const KSocketAddress *to)=0
This is an overloaded member function, provided for convenience. It differs from the above function o...
virtual qint64 writeData(const char *data, qint64 len)
Writes the given data to the socket.
Definition k3socketbase.cpp:430
void resetError()
Resets the socket error code and the I/O Device's status.
Definition k3socketbase.cpp:441
qint64 write(const char *data, qint64 len)
Writes the given data to the socket.
Definition k3socketbase.cpp:404
virtual KSocketAddress peerAddress() const =0
Return this socket's peer address, if we are connected.
virtual bool bind(const KResolverEntry &address)=0
Binds this socket to the given address.
virtual qint64 peekData(char *data, qint64 maxlen, KSocketAddress *from)=0
Peeks the data in the socket and the source address.
qint64 peek(char *data, qint64 maxlen)
Peeks the data in the socket and the source address.
Definition k3socketbase.cpp:394
virtual qint64 waitForMore(int msecs, bool *timeout=0L)=0
Waits up to msecs for more data to be available on this socket.
virtual qint64 readData(char *data, qint64 len)
Reads data from the socket.
Definition k3socketbase.cpp:425
virtual void setSocketDevice(KSocketDevice *device)
Definition k3socketbase.cpp:347
virtual bool listen(int backlog)=0
Puts this socket into listening mode.
virtual KSocketAddress localAddress() const =0
Returns this socket's local address.
virtual KSocketAddress externalAddress() const =0
Returns this socket's externally-visible address if known.
virtual bool bind(const KResolverEntry &address)=0
Binds this socket to the given address.
virtual KActiveSocketBase * accept()=0
Accepts a new incoming connection.
static void setError(QAbstractSocket *socket, QAbstractSocket::SocketError error, const QString &errorString)
Definition ksocketfactory.cpp:44
A namespace to store all networking-related (socket) classes.
Definition k3bufferedsocket.h:35
This file is part of the KDE documentation.
Documentation copyright © 1996-2025 The KDE developers.
Generated on Fri Jan 17 2025 00:00:00 by doxygen 1.13.2 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2025 The KDE developers.
Generated on Fri Jan 17 2025 00:00:00 by doxygen 1.13.2 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.