Сделал коннект и логин

This commit is contained in:
krivoshein
2024-12-03 17:38:06 +03:00
parent 27eda63932
commit c2ada0a8a5
219 changed files with 162385 additions and 1419 deletions

View File

@@ -0,0 +1,42 @@
#ifndef CONNECTORTOSERVER_H
#define CONNECTORTOSERVER_H
#include <QObject>
#include "Core\tcpclient.h"
#include "Core\dataparser.h"
#include "Core\sendsystem.h"
#include "Core\recognizesystem.h"
class ConnectorToServer : public QObject
{
Q_OBJECT
public:
explicit ConnectorToServer(QObject *parent = nullptr);
bool authorizationInstructorLocal(QString login, QString password);
private slots:
signals:
void sigSetConnect(ServerSettings* serverSettings,QThread *thread);
void sigInitializeClient(RecognizeSystem *recognizeSystem,
SendSystem *sendSystem,
QThread *thread);
void sigSendAutorization();
void sigLoginResult(ServerAuthorization * serverAuth);
private:
void initialize();
void bindConnection();
void createObjects();
private:
QThread *connectionThread;
TCPClient *client;
DataParser *dataParser;
SendSystem *sendSystem;
RecognizeSystem *recognizeSystem;
};
#endif // CONNECTORTOSERVER_H