aboutsummaryrefslogtreecommitdiffstats
path: root/src/diagram/iterator.cpp
diff options
context:
space:
mode:
authorNao Pross <naopross@thearcway.org>2018-01-01 18:44:35 +0100
committerNao Pross <naopross@thearcway.org>2018-01-01 18:44:35 +0100
commit7ea534dd1c8bf72200a999cae554d842d9035ba9 (patch)
tree6b2438ea6f7c27c8069458d599bfbf2ba5534ce7 /src/diagram/iterator.cpp
parentImplement basic ui (diff)
downloadOrbitingYeti-7ea534dd1c8bf72200a999cae554d842d9035ba9.tar.gz
OrbitingYeti-7ea534dd1c8bf72200a999cae554d842d9035ba9.zip
New StatementDialog, rename diagram classes
Other changes: - Use raw pointer instead of smart pointers to manage resources - Initial Painter implementation
Diffstat (limited to 'src/diagram/iterator.cpp')
-rw-r--r--src/diagram/iterator.cpp18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/diagram/iterator.cpp b/src/diagram/iterator.cpp
new file mode 100644
index 0000000..43085b4
--- /dev/null
+++ b/src/diagram/iterator.cpp
@@ -0,0 +1,18 @@
+#include "diagram/iterator.h"
+
+using namespace samb;
+
+Iterator::Iterator(Statement::Type t, const QString &condition, Statement::pointer next) :
+ Statement(t, condition, next),
+ _inner("")
+{
+
+ switch (t) {
+ case Statement::Type::WHILE:
+ case Statement::Type::UNTIL:
+ break;
+
+ default:
+ throw std::invalid_argument("IteratorStatement can only be of type WHILE or UNTIL");
+ }
+}