diff options
| author | 2020-07-11 00:45:44 +0200 | |
|---|---|---|
| committer | 2020-08-21 22:51:43 +0200 | |
| commit | 8087429c108c4f6bef5f792ce256b8d5b8b69101 (patch) | |
| tree | d847b1acadb3d4ac7166bda415794f61816de682 /include/diceparser.h | |
| parent | 35d019ec86f272d4189852a3e69ede403c415a8c (diff) | |
| download | OneRoll-8087429c108c4f6bef5f792ce256b8d5b8b69101.tar.gz OneRoll-8087429c108c4f6bef5f792ce256b8d5b8b69101.zip | |
Rework exporting
Diffstat (limited to 'include/diceparser.h')
| -rw-r--r-- | include/diceparser.h | 64 |
1 files changed, 3 insertions, 61 deletions
diff --git a/include/diceparser.h b/include/diceparser.h index eb4dee4..4d5555e 100644 --- a/include/diceparser.h +++ b/include/diceparser.h @@ -89,61 +89,10 @@ public: QList<DiceAlias*>* aliases() const; void cleanAliases(); void insertAlias(DiceAlias*, int); - /** - * @brief getErrorList - * @return - */ - QMap<Dice::ERROR_CODE, QString> errorMap() const; - /** - * @brief setPathToHelp set the path to the documentation, this path must be adatped to the lang of application etc… - * @param l the path. - */ - void setPathToHelp(QString l); - /** - * @brief allFirstResultAsString - * @return - */ + QString convertAlias(const QString& cmd) const; + QStringList allFirstResultAsString(bool& hasAlias); - /** - * @brief getAllDiceResult - * @param hasAlias - * @return - */ QStringList getAllDiceResult(bool& hasAlias); - /** - * @brief hasSeparator allows to know if the current command has separator. - * @return true when the command has separator, false otherwise. - */ - bool hasSeparator() const; -// beginning of strange code ||||||| parent of af8b69b... change the way diceparser is giving its result. - /** - * @brief getErrorList - * @return - */ - QMap<Dice::ERROR_CODE, QString> getErrorMap(); - /** - * @brief setPathToHelp set the path to the documentation, this path must be adatped to the lang of application etc… - * @param l the path. - */ - void setPathToHelp(QString l); - /** - * @brief getAllStringResult - * @return - */ - QStringList getAllStringResult(bool& hasAlias); - /** - * @brief getAllDiceResult - * @param hasAlias - * @return - */ - QStringList getAllDiceResult(bool& hasAlias); - /** - * @brief hasSeparator allows to know if the current command has separator. - * @return true when the command has separator, false otherwise. - */ - bool hasSeparator() const; -// END of strange code - QString convertAlias(const QString& cmd) const; // Accessors int startNodeCount() const; @@ -156,12 +105,11 @@ public: QString comment() const; QString humanReadableWarning() const; QString humanReadableError() const; - QJsonObject exportResult() const; + QString resultAsJSon() const; // QStringList stringResult() const; // QStringList allDiceResult(bool& hasAlias) const; // void lastDiceResult(QList<ExportedDiceResult>& diceValues, bool& homogeneous) const; - // QList<qreal> sumOfDiceResult() const; // setters void setPathToHelp(QString l); @@ -169,12 +117,6 @@ public: void setComment(const QString& comment); private: - /** - * @brief hasResultOfType - * @param notthelast - * @return - */ - bool hasResultOfType(Dice::RESULT_TYPE, ExecutionNode* node, QVariant& value, bool notthelast= false); bool readBlocInstruction(QString& str, ExecutionNode*& resultnode); private: |