aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/include
diff options
context:
space:
mode:
authorRenaud G <renaud@rolisteam.org>2021-02-07 02:43:54 +0100
committerRenaud G <renaud@rolisteam.org>2021-02-07 02:45:12 +0100
commitb9f44f8dffef37a182ed4b9fdba68c935a972026 (patch)
treec5dfc852cb7afcf0e70fe1b623d0d5253df01f7f /include
parent0bba02370a82719e47ba0566c3c56ea0b770c96c (diff)
downloadOneRoll-b9f44f8dffef37a182ed4b9fdba68c935a972026.tar.gz
OneRoll-b9f44f8dffef37a182ed4b9fdba68c935a972026.zip
Add SwitchCaseNode
Diffstat (limited to 'include')
-rw-r--r--include/parsingtoolbox.h40
1 files changed, 22 insertions, 18 deletions
diff --git a/include/parsingtoolbox.h b/include/parsingtoolbox.h
index 1817704..d83e063 100644
--- a/include/parsingtoolbox.h
+++ b/include/parsingtoolbox.h
@@ -40,6 +40,7 @@
class RepeaterNode;
class DiceAlias;
class ExplodeDiceNode;
+class SwitchCaseNode;
class SubtituteInfo
{
@@ -89,24 +90,25 @@ public:
};
enum OptionOperator
{
- KeepAndExplode,
- Keep,
- Reroll,
- RerollUntil,
- Explode,
- Sort,
- Count,
- RerollAndAdd,
- Merge,
- ifOperator,
- Painter,
- Filter,
- Split,
- Group,
- Occurences,
- Unique,
- Bind,
- AllSameExplode
+ KeepAndExplode, // K
+ Keep, // k
+ Reroll, // r
+ RerollUntil, // R
+ Explode, // e
+ Sort, // s
+ Count, // c
+ RerollAndAdd, // a
+ Merge, // m
+ ifOperator, // i
+ Painter, // p
+ Filter, // f
+ Split, // y
+ Group, // g
+ Occurences, // o
+ Unique, // u
+ Bind, // b
+ AllSameExplode, // t
+ SwitchCaseOption // S
};
enum DiceOperator
{
@@ -131,6 +133,7 @@ public:
// parsing tools
static bool readAscending(QString& str);
+ static bool readStopAtFirst(QString& str);
bool readLogicOperator(QString& str, BooleanCondition::LogicOperator& op);
Validator* readValidator(QString& str, bool hasSquare= false);
ValidatorList* readValidatorList(QString& str);
@@ -181,6 +184,7 @@ public:
bool readBlocInstruction(QString& str, ExecutionNode*& resultnode);
bool readOption(QString&, ExecutionNode* node); // OptionOperator& option,
bool readValuesList(QString& str, ExecutionNode*& node);
+ bool readSwitchCaseNode(QString& str, SwitchCaseNode* node);
// Error
bool hasError() const;