git-svn-id: http://find-object.googlecode.com/svn/trunk/find_object@243 620bd6b2-0a58-f614-fd9a-1bd335dccda9
29 lines
465 B
C++
29 lines
465 B
C++
/*
|
|
* TCPClient.h
|
|
*
|
|
* Created on: 2014-05-05
|
|
* Author: mathieu
|
|
*/
|
|
|
|
#ifndef TCPCLIENT_H_
|
|
#define TCPCLIENT_H_
|
|
|
|
#include <QtNetwork/QTcpSocket>
|
|
|
|
class TcpClient : public QTcpSocket
|
|
{
|
|
Q_OBJECT;
|
|
public:
|
|
TcpClient(const QString & hostname, quint16 port, QObject * parent = 0);
|
|
|
|
private slots:
|
|
void readData();
|
|
void displayError(QAbstractSocket::SocketError socketError);
|
|
void connectionLost();
|
|
|
|
private:
|
|
quint16 blockSize_;
|
|
};
|
|
|
|
#endif /* TCPCLIENT_H_ */
|