ref: add postprocess and dataparserOut

This commit is contained in:
semenov
2025-08-12 10:24:37 +03:00
parent c993e12b84
commit f5c929021b
10 changed files with 28 additions and 17566 deletions

View File

@@ -8,9 +8,9 @@ DataParser::DataParser(QObject *parent) :
} }
} }
void DataParser::initialize() void DataParser::initialize(PostProcessorSystem *postProcessSystem)
{ {
this->postProcessSystem = postProcessSystem;
} }
@@ -118,17 +118,17 @@ void DataParser::xmlParser(QByteArray array)
{ {
if (value == "END") if (value == "END")
{ {
postProcessorSystem->socketDisable(); postProcessSystem->socketDisable();
} }
if (value == "BLOCKED") if (value == "BLOCKED")
{ {
postProcessorSystem->serverBlocked(); postProcessSystem->serverBlocked();
} }
if (value == "HASHSENDCOMPLETE") if (value == "HASHSENDCOMPLETE")
{ {
postProcessorSystem->startCompare(); postProcessSystem->startCompare();
} }
if (value == "BASEDELETETRY") if (value == "BASEDELETETRY")
@@ -149,13 +149,13 @@ void DataParser::xmlParser(QByteArray array)
if (value == "UNCHANGEABLE") if (value == "UNCHANGEABLE")
{ {
emit sigNotify(tr("Нельзя выгружать в базовую версию")); emit sigNotify(tr("Нельзя выгружать в базовую версию"));
postProcessorSystem->showUpdateList(); postProcessSystem->showUpdateList();
//emit recognizeSystem->sigShowUpdateList(); //emit recognizeSystem->sigShowUpdateList();
} }
if (value == "CHANGEABLE") if (value == "CHANGEABLE")
{ {
postProcessorSystem->compareFiles(); postProcessSystem->compareFiles();
//emit sigUpdateFilesOnServer(hashComparer->getFilesForUpdate()); //emit sigUpdateFilesOnServer(hashComparer->getFilesForUpdate());
} }
} }
@@ -185,12 +185,12 @@ void DataParser::xmlParser(QByteArray array)
if (name == "AccessType"){ if (name == "AccessType"){
serverAuth->AccessType = value; serverAuth->AccessType = value;
postProcessorSystem->checkAccessType(value); postProcessSystem->checkAccessType(value);
//recognizeSystem->checkAccessType(value); //recognizeSystem->checkAccessType(value);
} }
} }
postProcessorSystem->saveLoginData(serverAuth); postProcessSystem->saveLoginData(serverAuth);
//emit recognizeSystem->sigSaveLoginData(serverAuth); //emit recognizeSystem->sigSaveLoginData(serverAuth);
} }
@@ -218,7 +218,7 @@ void DataParser::xmlParser(QByteArray array)
} }
} }
postProcessorSystem->setServerVersion(serverVersion); postProcessSystem->setServerVersion(serverVersion);
//recognizeSystem->setServerVersion(serverVersion); //recognizeSystem->setServerVersion(serverVersion);
} }
@@ -256,7 +256,7 @@ void DataParser::xmlParser(QByteArray array)
xmlReader.readNext(); xmlReader.readNext();
} }
postProcessorSystem->showServerDataList(serverStreamingVersionDataList); postProcessSystem->showServerDataList(serverStreamingVersionDataList);
} }
xmlReader.readNext(); xmlReader.readNext();

View File

@@ -21,7 +21,7 @@ class DataParser : public QObject
public: public:
explicit DataParser(QObject *parent = 0); explicit DataParser(QObject *parent = 0);
void initialize(); void initialize(PostProcessorSystem *postProcessSystem);
~DataParser(); ~DataParser();
ServerSettings* getClientSettings(); ServerSettings* getClientSettings();
@@ -33,7 +33,7 @@ signals:
private: private:
ClientAutorization *authPassCache; ClientAutorization *authPassCache;
PostProcessorSystem *postProcessorSystem; PostProcessorSystem *postProcessSystem;
}; };
#endif // DATAPARSER_H #endif // DATAPARSER_H

View File

@@ -1,6 +1,6 @@
#include "postprocessorsystem.h" #include "postprocessorsystem.h"
PostProcessorSystem::PostProcessorSystem() {} PostProcessorSystem::PostProcessorSystem(QObject *parent) : QObject(parent){}
void PostProcessorSystem::initialize(DataParserOutput *dataParserOutput, void PostProcessorSystem::initialize(DataParserOutput *dataParserOutput,
HashComparer *hashComparer, HashComparer *hashComparer,

View File

@@ -10,7 +10,7 @@ class PostProcessorSystem : public QObject
{ {
Q_OBJECT Q_OBJECT
public: public:
PostProcessorSystem(); explicit PostProcessorSystem(QObject *parent = 0);
void initialize(DataParserOutput *dataParserOutput, void initialize(DataParserOutput *dataParserOutput,
HashComparer *hashComparer, HashComparer *hashComparer,
VersionContainer* versionContainer, VersionContainer* versionContainer,

View File

@@ -19,10 +19,11 @@ RecognizeSystem::~RecognizeSystem()
} }
void RecognizeSystem::initialize(VersionContainer *versionContainer,PostProcessorSystem *postProcessorSystem) void RecognizeSystem::initialize(DataParser *dataParser, VersionContainer *versionContainer,PostProcessorSystem *postProcessorSystem)
{ {
this->versionContainer = versionContainer; this->versionContainer = versionContainer;
this->postProcessorSystem = postProcessorSystem; this->postProcessorSystem = postProcessorSystem;
this->dataParser = dataParser;
} }
void RecognizeSystem::recognize(QTcpSocket *socket) void RecognizeSystem::recognize(QTcpSocket *socket)

View File

@@ -23,7 +23,7 @@ class RecognizeSystem : public QObject
public: public:
explicit RecognizeSystem(QObject *parent = 0); explicit RecognizeSystem(QObject *parent = 0);
~RecognizeSystem(); ~RecognizeSystem();
void initialize(VersionContainer* versionContainer,PostProcessorSystem *postProcessorSystem); void initialize(DataParser *dataParser, VersionContainer* versionContainer,PostProcessorSystem *postProcessorSystem);
void recognize(QTcpSocket *socket); void recognize(QTcpSocket *socket);
void showServerDataList(QList<StreamingVersionData*> *showServerDataList); void showServerDataList(QList<StreamingVersionData*> *showServerDataList);

File diff suppressed because it is too large Load Diff

View File

@@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version="1.0" encoding="UTF-8"?>
<ServerSettingsContainer> <ServerSettingsContainer>
<ServerSettings DestPortMath="18003" Port="6000" AutoStart="0" UseMathModel="1" Language="RUS" Address="192.168.100.83" LocalPortMath="18004"/> <ServerSettings Address="192.168.100.83" Port="6000" Language="RUS" AutoStart="0" DestPortMath="18003" LocalPortMath="18004" UseMathModel="1"/>
<VersionData Version="base" isChangable="0" Created="Пт авг 1 10:37:32 2025"/> <VersionData Version="" isChangable="13"/>
</ServerSettingsContainer> </ServerSettingsContainer>

File diff suppressed because it is too large Load Diff

View File

@@ -31,6 +31,8 @@ void MainWindow::createObjects()
updateWidget->setParent(this); updateWidget->setParent(this);
commonButtonGroupWidget = new CommonButtonGroupWidget; commonButtonGroupWidget = new CommonButtonGroupWidget;
instructorButtonGroup = new InstructorButtonGroupWidget;
entryWidget = new EntryWidget; entryWidget = new EntryWidget;
versionSelectWidget = new VersionSelectWidget; versionSelectWidget = new VersionSelectWidget;
waitAnimationWidget = new WaitAnimationWidget; waitAnimationWidget = new WaitAnimationWidget;
@@ -108,8 +110,9 @@ void MainWindow::initialize()
versionSelectWidget->initialize(sendSystem,versionContainer,notifyController); versionSelectWidget->initialize(sendSystem,versionContainer,notifyController);
hashComparer->initialize(versionContainer); hashComparer->initialize(versionContainer);
updateController->initialize(versionContainer); updateController->initialize(versionContainer);
dataParser->initialize(); postProcessorSystem->initialize(dataParserOutput,hashComparer,versionContainer,updateController);
recognizeSystem->initialize(versionContainer,postProcessorSystem); dataParser->initialize(postProcessorSystem);
recognizeSystem->initialize(dataParser, versionContainer, postProcessorSystem);
resourceManager->painting(); resourceManager->painting();
commonButtonGroupWidget->initialize(externalExecuter,sendSystem,client); commonButtonGroupWidget->initialize(externalExecuter,sendSystem,client);
commonButtonGroupWidget->show(); commonButtonGroupWidget->show();