35 lines
981 B
C
35 lines
981 B
C
|
|
#ifndef CIMPARSERBATCH_H
|
|||
|
|
#define CIMPARSERBATCH_H
|
|||
|
|
#include <QtCore>
|
|||
|
|
#include <QDir>
|
|||
|
|
#include <QStringList>
|
|||
|
|
#include <iostream>
|
|||
|
|
#include <QFile>
|
|||
|
|
#include <QObject>
|
|||
|
|
class CIMParserBatch:public QObject
|
|||
|
|
{
|
|||
|
|
Q_OBJECT
|
|||
|
|
public:
|
|||
|
|
typedef struct
|
|||
|
|
{
|
|||
|
|
double p;
|
|||
|
|
double q;
|
|||
|
|
}FeederData;
|
|||
|
|
CIMParserBatch();
|
|||
|
|
void parser(const QString& dir,const QString& scadaDataFilePath);
|
|||
|
|
private:
|
|||
|
|
QString FindXML(const QString& dir);//返回的是绝对路径
|
|||
|
|
QFileInfoList FindiPsoPrefixedFile(const QString& dir);//得到那些解析得到的文体局,是有前缀的。
|
|||
|
|
void ReadscadaData(const QString& dataPath);
|
|||
|
|
void GenerateBatchFile(const QString& batFilePath);//直接生成一个bat文件算了。
|
|||
|
|
void CallFunParser();
|
|||
|
|
private slots:
|
|||
|
|
void ExecuteParserApp(QThread *);
|
|||
|
|
private:
|
|||
|
|
QFileInfoList::const_iterator mite;//parser函数里用的
|
|||
|
|
QFileInfoList mdirList;
|
|||
|
|
QHash<QString,FeederData> mScada;
|
|||
|
|
};
|
|||
|
|
|
|||
|
|
#endif // CIMPARSERBATCH_H
|