47 lines
788 B
C++
Executable File
47 lines
788 B
C++
Executable File
#pragma once
|
|
|
|
#include <QObject>
|
|
#include <QString>
|
|
#include <QVector>
|
|
|
|
struct CommandInfo {
|
|
QString name;
|
|
QString description;
|
|
QString callbackFunction;
|
|
};
|
|
|
|
class GenCode : public QObject
|
|
{
|
|
Q_OBJECT
|
|
public:
|
|
GenCode(QObject *parent = nullptr);
|
|
~GenCode();
|
|
|
|
public:
|
|
int analyzePrjFile(QString prjPath);
|
|
bool genCMakeFile();
|
|
bool genHeaderFile();
|
|
bool genSourceFile();
|
|
bool genPrivateHeaderFile();
|
|
bool genConfigFile();
|
|
bool genGlobalFile();
|
|
|
|
private:
|
|
QString codePath;
|
|
QString modelName;
|
|
QString className;
|
|
QString author;
|
|
QString version;
|
|
QString description;
|
|
QString createTime;
|
|
QString changeTime;
|
|
QString node;
|
|
QString priority;
|
|
QString mathPath;
|
|
QString mathHeaderPath;
|
|
QString mathEntryPoint;
|
|
QString mathEntryParam;
|
|
|
|
QVector<CommandInfo> commandList;
|
|
};
|