diff -r 56cd8111b7f7 -r 41300fa6a67c tests/qtp/qtp_qftp/ftpserver.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/qtp/qtp_qftp/ftpserver.h Tue Feb 02 00:43:10 2010 +0200 @@ -0,0 +1,40 @@ +#ifndef FTPSERVER_H +#define FTPSERVER_H + +#include +#include + + class ftpServer : public QTcpServer // , public QThread + { + Q_OBJECT + + public: + ftpServer( QObject *parent = 0 ); + ~ftpServer(); + + bool isDone(); +// void run(); +/* +private: + void sendSomething( QTcpSocket *outSock, quint16 port ); +*/ +private slots: + void handleNewConnection(); + void readConnection(); + void displayConnectionError(QAbstractSocket::SocketError socketError); + + void readDataConnection(); + void handleNewDataConnection(); + void displayDataConnectionError(QAbstractSocket::SocketError socketError); + + private: + QTcpServer *tcpServer; + QTcpSocket *ftpSocket; + + QTcpServer *dataServer; + QTcpSocket *dataSocket; + + bool not_done; +}; + +#endif // FTPSERVER_H