blob: de9fc05d507925be431c579f4c10467b4b5da499 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
#include "testnode.h"
#include "die.h"
TestNode::TestNode() {}
TestNode::~TestNode()
{
m_nextNode= nullptr;
m_result= nullptr;
}
void TestNode::run(ExecutionNode* previous)
{
Q_UNUSED(previous)
if(nullptr != m_nextNode)
{
m_nextNode->run(this);
}
}
QString TestNode::toString(bool wl) const
{
if(wl)
{
return QStringLiteral("%1 [label=\"TestNode \"]").arg(m_id);
}
else
{
return m_id;
}
}
qint64 TestNode::getPriority() const
{
qint64 priority= 4;
return priority;
}
ExecutionNode* TestNode::getCopy() const
{
TestNode* node= new TestNode();
if(nullptr != m_nextNode)
{
node->setNextNode(m_nextNode->getCopy());
}
return node;
}
void TestNode::setResult(Result* result)
{
m_result= result;
}
|