- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files
- Directories
- Examples

- Class List
- Class Hierarchy
- Class Members

Signals | Public Member Functions | Protected Member Functions

# QTcpServer Class Reference

Search for all occurrences

## Detailed Description

Definition at line 61 of file qtcpserver.h.

`#include <qtcpserver.h>`

Inheritance diagram for QTcpServer:
[legend]

List of all members.

## Signals
void | newConnection ()
## Public Member Functions
| QTcpServer (QObject *parent=0)
virtual | ~QTcpServer ()
bool | listen (const QHostAddress &address=QHostAddress::Any, quint16 port=0)
void | close ()
bool | isListening () const
void | setMaxPendingConnections (int numConnections)
int | maxPendingConnections () const
quint16 | serverPort () const
QHostAddress | serverAddress () const
int | socketDescriptor () const
bool | setSocketDescriptor (int socketDescriptor)
bool | waitForNewConnection (int msec=0, bool *timedOut=0)
virtual bool | hasPendingConnections () const
virtual QTcpSocket * | nextPendingConnection ()
QAbstractSocket::SocketError | serverError () const
QString | errorString () const
void | setProxy (const QNetworkProxy &networkProxy)
QNetworkProxy | proxy () const
## Protected Member Functions
virtual void | incomingConnection (int handle)
void | addPendingConnection (QTcpSocket *socket)

## Constructor & Destructor Documentation

QTcpServer | ( | QObject * | parent = `0` | ) | `[explicit]`

virtual ~QTcpServer | ( |  | ) | `[virtual]`

## Member Function Documentation

bool listen | ( | const QHostAddress & | address = `QHostAddress::Any`,
|  | quint16 | port = `0`
| ) |  |

Search for all occurrences

void close | ( |  | ) |

Search for all occurrences

bool isListening | ( |  | ) | const

Search for all occurrences

void setMaxPendingConnections | ( | int | numConnections | ) |

Search for all occurrences

int maxPendingConnections | ( |  | ) | const

Search for all occurrences

quint16 serverPort | ( |  | ) | const

Search for all occurrences

QHostAddress serverAddress | ( |  | ) | const

Search for all occurrences

int socketDescriptor | ( |  | ) | const

Search for all occurrences

bool setSocketDescriptor | ( | int | socketDescriptor | ) |

Search for all occurrences

bool waitForNewConnection | ( | int | msec = `0`,
|  | bool * | timedOut = `0`
| ) |  |

Search for all occurrences

virtual bool hasPendingConnections | ( |  | ) | const `[virtual]`

Search for all occurrences

virtual QTcpSocket* nextPendingConnection | ( |  | ) | `[virtual]`

Search for all occurrences

QAbstractSocket::SocketError serverError | ( |  | ) | const

Search for all occurrences

QString errorString | ( |  | ) | const

Search for all occurrences

void setProxy | ( | const QNetworkProxy & | networkProxy | ) |

Search for all occurrences

QNetworkProxy proxy | ( |  | ) | const

Search for all occurrences

virtual void incomingConnection | ( | int | handle | ) | `[protected, virtual]`

Search for all occurrences

void addPendingConnection | ( | QTcpSocket * | socket | ) | `[protected]`

Search for all occurrences

void newConnection | ( |  | ) | `[signal]`

Search for all occurrences

The documentation for this class was generated from the following file:

- QtNetwork/qtcpserver.h

QTcpServer QTcpServer QTcpServer QTcpServer QTcpServer QTcpServer QTcpServer QTcpServer QTcpServer QTcpServer
QTcpServer QTcpServer QTcpServer QTcpServer QTcpServer QTcpServer QTcpServer QTcpServer QTcpServer QTcpServer