1#ifndef DACOMMANDSFORWORKFLOWNODEGRAPHICS_H
2#define DACOMMANDSFORWORKFLOWNODEGRAPHICS_H
3#include "DAWorkFlowAPI.h"
10#include "DANodeMetaData.h"
11#include "DANodeLinkPoint.h"
12#include "DAAbstractNode.h"
17class DAAbstractNodeLinkGraphicsItem;
18class DAGraphicsPixmapItem;
19class DANodeGraphicsScene;
20class DAWorkFlowGraphicsScene;
21class DAAbstractNodeGraphicsItem;
23class DAGraphicsStandardTextItem;
36 bool addItemToScene =
true,
37 QUndoCommand* parent =
nullptr);
44 DAAbstractNode::SharedPointer node()
const;
50 DAAbstractNode::SharedPointer mNode;
51 bool mAddItemToScene {
true };
54 bool mSkipFirstRedo {
true };
64 const QList< DAAbstractNode::SharedPointer >& ns,
65 QUndoCommand* par =
nullptr);
71 QPointer< DAWorkFlow > mWorkflow;
72 QList< DAAbstractNode::SharedPointer > mNodes;
84 QUndoCommand* parent =
nullptr);
92 DAAbstractNode::SharedPointer mNode;
107 QUndoCommand* parent =
nullptr);
112 QList< DAAbstractNodeLinkGraphicsItem* > getRemovedNodeLinkItems()
const;
117 DAAbstractNode::SharedPointer mWillRemoveNode;
118 QList< DAAbstractNodeLinkGraphicsItem* > mWillRemoveLink;
134 QList< DAAbstractNodeGraphicsItem* >& nodeItems,
135 QList< DAAbstractNodeLinkGraphicsItem* >& linkItems,
136 QList< QGraphicsItem* >& normalItem);
138 static QList< DAAbstractNodeLinkGraphicsItem* > getNodesLinks(
const QList< DAAbstractNodeGraphicsItem* >& nodeItems);
140 bool isValid()
const;
142 int removeCount()
const;
144 QList< DAAbstractNodeGraphicsItem* > getRemovedNodeItems()
const;
145 QList< DAAbstractNodeLinkGraphicsItem* > getRemovedNodeLinkItems()
const;
146 QList< QGraphicsItem* > getAllRemovedItems()
const;
151 QList< DAAbstractNodeGraphicsItem* > mSelectNodeItems;
152 QList< DAAbstractNodeLinkGraphicsItem* > mWillRemoveLink;
153 QList< QGraphicsItem* > mWillRemoveNormal;
154 QList< DAAbstractNode::SharedPointer > mWillRemoveNodes;
167 QUndoCommand* parent =
nullptr);
169 void redo()
override;
170 void undo()
override;
176 QString mFromPointName;
177 QString mToPointName;
192 QUndoCommand* parent =
nullptr);
194 void redo()
override;
195 void undo()
override;
201 QString mFromPointName;
202 QString mToPointName;
这是节点的基类,workflow所有节点都继承此类 作为一个节点的QGraphicsItem,此item应该由DAAbstractNode创建
Definition DAAbstractNodeGraphicsItem.h:47
绘制连接线的item
Definition DAAbstractNodeLinkGraphicsItem.h:20
节点添加命令
Definition DACommandsForWorkFlowNodeGraphics.h:80
创建link
Definition DACommandsForWorkFlowNodeGraphics.h:162
节点创建命令
Definition DACommandsForWorkFlowNodeGraphics.h:31
移除link
Definition DACommandsForWorkFlowNodeGraphics.h:187
节点删除命令
Definition DACommandsForWorkFlowNodeGraphics.h:103
移除节点命令
Definition DACommandsForWorkFlowNodeGraphics.h:61
The 节点删除命令
Definition DACommandsForWorkFlowNodeGraphics.h:127
DAAbstractNodeGraphicsItem对应的QGraphicsScene,通过此scene,管理DAWorkFlow内容
Definition DANodeGraphicsScene.h:25
基本的工作流,这个也是总工厂,汇总了所有插件的工厂
Definition DAWorkFlow.h:21
序列化类都是带异常的,使用中需要处理异常
Definition AppMainWindow.cpp:44