diff options
| author | 2015-08-20 12:25:21 +0200 | |
|---|---|---|
| committer | 2015-08-20 12:25:21 +0200 | |
| commit | 831f75a83ca3e5734d3c110af584a0f3bf7430e7 (patch) | |
| tree | 6417d0f3855782cd1875b701d3a117c277d7c4d4 /result/result.cpp | |
| parent | 1dc11051931fd074b886a4e1fe0df5d747e87e20 (diff) | |
| download | OneRoll-831f75a83ca3e5734d3c110af584a0f3bf7430e7.tar.gz OneRoll-831f75a83ca3e5734d3c110af584a0f3bf7430e7.zip | |
add bool for toString() in result.
Diffstat (limited to 'result/result.cpp')
| -rw-r--r-- | result/result.cpp | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/result/result.cpp b/result/result.cpp index 257045c..6451e63 100644 --- a/result/result.cpp +++ b/result/result.cpp @@ -20,9 +20,10 @@ * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * ***************************************************************************/ #include "result.h" +#include <QUuid> Result::Result() - : m_previous(NULL) + : m_previous(NULL),m_id(QUuid::createUuid().toString()) { } @@ -47,22 +48,22 @@ bool Result::hasResultOfType(RESULT_TYPE type) const } void Result::generateDotTree(QString& s) { - s.append(toString()); + s.append(toString(true)); + s.append(";\n"); + if(NULL!=m_previous) { + s.append(toString(false)); s.append(" -> "); - s.append(m_previous->toString()); - s.append(" [label=\"previousResult\"];\n"); + s.append(m_previous->toString(true)); + s.append("\n"); m_previous->generateDotTree(s); } { s.append(" -> "); - s.append("NULL"); + s.append("NULL;\n"); s.append(" [label=\"previousResult\"];\n"); } } -/*QString Result::toString() -{ - return QString(); -}*/ + |