From 530c87f71366810549b718160bc59bda51f876b0 Mon Sep 17 00:00:00 2001 From: Renaud G Date: Sat, 30 Jan 2016 17:52:00 +0100 Subject: -rework arithmetic operator --- node/scalaroperatornode.h | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'node/scalaroperatornode.h') diff --git a/node/scalaroperatornode.h b/node/scalaroperatornode.h index ca6f3ac..a8f930a 100644 --- a/node/scalaroperatornode.h +++ b/node/scalaroperatornode.h @@ -35,11 +35,11 @@ class ScalarOperatorNode : public ExecutionNode { public: - enum ScalarOperator {PLUS,MINUS,DIVIDE,MULTIPLICATION}; + enum ArithmeticOperator {PLUS,MINUS,DIVIDE,MULTIPLICATION}; ScalarOperatorNode(); virtual ~ScalarOperatorNode(); virtual void run(ExecutionNode*); - bool setOperatorChar(QChar c); + void setInternalNode(ExecutionNode* node); virtual QString toString(bool wl)const; @@ -52,6 +52,9 @@ public: */ virtual QMap getExecutionErrorMap(); + ScalarOperatorNode::ArithmeticOperator getArithmeticOperator() const; + void setArithmeticOperator(const ScalarOperatorNode::ArithmeticOperator &arithmeticOperator); + private: static qint64 add(qint64,qint64); static qint64 substract(qint64,qint64); @@ -59,10 +62,9 @@ private: static qint64 multiple(qint64,qint64); private: - ScalarOperator m_operator; + ArithmeticOperator m_arithmeticOperator; ScalarResult* m_scalarResult; ExecutionNode* m_internalNode; - QMap m_scalarOperationList; }; #endif // SCALAROPERATORNODE_H -- cgit v1.2.3-70-g09d2