last changes
This commit is contained in:
36
AdServer/clientbase.h
Normal file
36
AdServer/clientbase.h
Normal file
@@ -0,0 +1,36 @@
|
||||
#ifndef CLIENTBASE_H
|
||||
#define CLIENTBASE_H
|
||||
|
||||
#include <QObject>
|
||||
#include <QTcpSocket>
|
||||
#include <QHostAddress>
|
||||
#include <QByteArray>
|
||||
#include "message.h"
|
||||
|
||||
|
||||
class ClientBase : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
explicit ClientBase(QObject *parent = 0);
|
||||
~ClientBase();
|
||||
void closeConnection();
|
||||
QString getStatus();
|
||||
void send(const QByteArray &ba);
|
||||
|
||||
public slots:
|
||||
|
||||
protected:
|
||||
QTcpSocket * m_socket;
|
||||
|
||||
protected slots:
|
||||
virtual void readData();
|
||||
virtual void Disconnection();
|
||||
|
||||
signals:
|
||||
void disconnected();
|
||||
void receive(QByteArray ba);
|
||||
|
||||
};
|
||||
|
||||
#endif // CLIENTBASE_H
|
||||
Reference in New Issue
Block a user