- Extending Qt Creator Manual
- TaskTree
- QTcpSocketWrapper
- Extending Qt Creator Manual 19.0.2

# QTcpSocketWrapper Class

A wrapper around QTcpSocket. More...

Header: | `#include <qtcpsocketwrappertask.h>`

- List of all members, including inherited members

Note: All functions in this class are reentrant.

## Signals

void | done(QtTaskTree::DoneResult result)
void | started()

## Detailed Description

QTcpSocketWrapper is a convenient wrapper around QTcpSocket.

Configure the QTcpSocketWrapper with setAddress(), setPort(), and setData() before calling start().

The wrapped QTcpSocket may be accessed via socket() method. The QTcpSocket is created dynamically by the start() method and managed by QTcpSocketWrapper. It is deleted just after emitting done() signal.

## Member Function Documentation

### `[signal]` void QTcpSocketWrapper::done(QtTaskTree::DoneResult result)

This signal is emitted after the associated QTcpSocket finished. The passed result indicates whether it has finished with success or an error.

See also socket().

### `[signal]` void QTcpSocketWrapper::started()

This signal is emitted after the managed QTcpSocket is connected.

See also start().