KDECore
k3socketdevice.cpp
Go to the documentation of this file.
463 static int do_read_common(int sockfd, char *data, qint64 maxlen, KSocketAddress* from, ssize_t &retval, bool peek = false)
virtual bool listen(int backlog=5)
Puts this socket into listening mode.
Definition: k3socketdevice.cpp:324
virtual qint64 writeData(const char *data, qint64 len, const KSocketAddress *to=0L)
Writes the given data to the given destination address.
Definition: k3socketdevice.cpp:536
#define T
virtual KSocketDevice * accept()
Accepts a new incoming connection.
Definition: k3socketdevice.cpp:382
virtual QString toString() const
Returns this socket address as a string suitable for printing.
Definition: k3socketaddress.cpp:606
KSocketAddress & setLength(quint16 len)
Sets the length of this socket structure.
Definition: k3socketaddress.cpp:480
void resetError()
Resets the socket error code and the I/O Device's status.
Definition: k3socketbase.cpp:441
QSocketNotifier * writeNotifier() const
Returns a socket notifier for output on this socket.
Definition: k3socketdevice.cpp:665
virtual bool connect(const KResolverEntry &address, OpenMode mode=ReadWrite)
Connect to a remote host.
Definition: k3socketdevice.cpp:345
virtual int capabilities() const
Returns the set of capabilities this socket class implements.
Definition: k3socketdevice.cpp:132
const sockaddr * address() const
Returns the socket address structure, to be passed down to low level functions.
Definition: k3socketaddress.cpp:449
virtual bool setSocketOptions(int opts)
This implementation sets the options on the socket.
Definition: k3socketdevice.cpp:137
QSocketNotifier * exceptionNotifier() const
Returns a socket notifier for exceptional events on this socket.
Definition: k3socketdevice.cpp:683
virtual QSocketNotifier * createNotifier(QSocketNotifier::Type type) const
Creates a socket notifier of the given type.
Definition: k3socketdevice.cpp:829
int protocol() const
Retrieves the protocol associated with this entry.
Definition: k3resolver.cpp:171
virtual KSocketAddress & setFamily(int family)
Sets the family of this object.
Definition: k3socketaddress.cpp:494
QSocketNotifier * readNotifier() const
Returns a socket notifier for input on this socket.
Definition: k3socketdevice.cpp:647
static void addNewImpl(KSocketDeviceFactoryBase *factory, int capabilities)
Adds a factory of KSocketDevice objects to the list, along with its capabilities flag.
Definition: k3socketdevice.cpp:915
virtual bool bind(const KResolverEntry &address)
Binds this socket to the given address.
Definition: k3socketdevice.cpp:293
virtual bool create(int family, int type, int protocol)
Creates a socket but don't connect or bind anywhere.
Definition: k3socketdevice.cpp:261
Definition: k3socketbase.h:115
virtual qint64 readData(char *data, qint64 maxlen, KSocketAddress *from=0L)
Reads data and the source address from this socket.
Definition: k3socketdevice.cpp:494
virtual qint64 peekData(char *data, qint64 maxlen, KSocketAddress *from=0L)
Peeks the data in the socket and the source address.
Definition: k3socketdevice.cpp:515
virtual bool setSocketOptions(int opts)
Set the given socket options.
Definition: k3socketbase.cpp:86
static int do_read_common(int sockfd, char *data, qint64 maxlen, KSocketAddress *from, ssize_t &retval, bool peek=false)
Definition: k3socketdevice.cpp:463
qint64 write(const char *data, qint64 len)
Writes the given data to the socket.
Definition: k3socketbase.cpp:404
KSocketAddress address() const
Retrieves the socket address associated with this entry.
Definition: k3resolver.cpp:135
static KSocketDeviceFactoryBase * setDefaultImpl(KSocketDeviceFactoryBase *factory)
Sets the default KSocketDevice implementation to use and return the old factory.
Definition: k3socketdevice.cpp:907
static KSocketDeviceFactoryBase * defaultImplFactory
Definition: k3socketdevice.cpp:872
virtual void setSocketDevice(KSocketDevice *device)
Definition: k3socketbase.cpp:347
virtual KSocketDevice * create(KSocketBase *) const =0
KSocketDevice(const KSocketBase *=0L, QObject *objparent=0L)
Default constructor.
Definition: k3socketdevice.cpp:87
quint16 length() const
Retrieves the length of the socket address structure.
Definition: k3resolver.cpp:141
int socketType() const
Retrieves the socket type associated with this entry.
Definition: k3resolver.cpp:165
void output(QList< Action > actions, QHash< QString, QString > domain)
Definition: fake/kauth-policy-gen-polkit.cpp:41
virtual qint64 waitForMore(int msecs, bool *timeout=0L)
Waits up to msecs for more data to be available on this socket.
Definition: k3socketdevice.cpp:451
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: k3socketdevice.cpp:701
quint16 length() const
Returns the length of this socket address structure.
Definition: k3socketaddress.cpp:473
virtual KSocketAddress localAddress() const
Returns this socket's local address.
Definition: k3socketdevice.cpp:568
virtual KSocketAddress peerAddress() const
Returns this socket's peer address.
Definition: k3socketdevice.cpp:604
int family() const
Retrieves the family associated with this socket address.
Definition: k3resolver.cpp:147
virtual int socketOptions() const
Retrieves the socket options that have been set.
Definition: k3socketbase.cpp:92
virtual KSocketAddress externalAddress() const
Returns this socket's externally visible local address.
Definition: k3socketdevice.cpp:640
static KSocketDevice * createDefault(KSocketBase *parent)
Creates a new default KSocketDevice object given the parent object.
Definition: k3socketdevice.cpp:877
virtual qint64 bytesAvailable() const
Returns the number of bytes available for reading without blocking.
Definition: k3socketdevice.cpp:439
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:47:07 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:47:07 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.