DiagramDesigner/diagramUtils/include/projectManager.h

44 lines
1.5 KiB
C
Raw Normal View History

2025-10-24 21:11:07 +08:00
#ifndef PROJECTMANAGER_H
#define PROJECTMANAGER_H
#include <QObject>
#include "global.h"
#include "export.hpp"
/****工程管理类
*
*****/
class DIAGRAM_DESIGNER_PUBLIC ProjectManager : public QObject
{
Q_OBJECT
public:
explicit ProjectManager(QObject *parent = nullptr);
~ProjectManager();
static ProjectManager& instance();
2025-10-30 17:20:10 +08:00
void saveEditorDataToDB(QUuid,const QString&,const QString&,QByteArray,QString autor,QString sTime);
QByteArray getEditorBaseSettingByUid(QUuid);
2025-10-24 21:11:07 +08:00
2025-10-30 17:20:10 +08:00
bool createEditorProject(const QString&); //创建项目
void unloadEditorProject(const QString&); //卸载项目
void openSetting(const QString&);
2025-10-24 21:11:07 +08:00
void saveEditor(const QString&);
2025-10-30 17:20:10 +08:00
bool deleteEditor(const QString&,QUuid); //删除当前版本
void loadBaseSetting(const QString& str,QUuid id); //加载wizard与基模拓扑设置
QList<editorBaseSettingInfo> getBaseSettingsByProject(const QString&); //获取工程名对应的设置列表
editorBaseSettingInfo getBaseSetting(QUuid); //获取设置
2025-10-24 21:11:07 +08:00
signals:
2025-10-30 17:20:10 +08:00
void prepareUnloadProject(const QString&);
void prepareOpenSetting(const QString& str);
2025-10-24 21:11:07 +08:00
void createNewEditor(const QString& str,QUuid id);
2025-10-30 17:20:10 +08:00
void editorSaved(const QString& strPro,const QString& autor,QUuid uid,QString sTime);
2025-10-24 21:11:07 +08:00
void prepareSaveEditor(QString);
2025-10-30 17:20:10 +08:00
void prepareLoadBaseSetting(const QString& str,QUuid id);
void prepareDeleteBaseSetting(const QString& str,QUuid id);
2025-10-24 21:11:07 +08:00
};
#endif // PROJECTMANAGER_H