CCIMXDesktop
 
Loading...
Searching...
No Matches
BinaryOpTreeNode.h
1#ifndef BINARYOPTREENODE_H
2#define BINARYOPTREENODE_H
3#include "ParseExceptions.h"
4#include "core/TreeNodeBase.h"
5#include <QChar>
12public:
20 BinaryOpTreeNode(QChar op,
21 TreeNodeBase* left_hand,
22 TreeNodeBase* right_hand);
23 BinaryOpTreeNode() = delete;
24 ~BinaryOpTreeNode() override;
30 double evaluate() const override;
31
32private:
33 QChar op;
34 TreeNodeBase* left_hand;
35 TreeNodeBase* right_hand;
36};
37
38#endif // BINARYOPTREENODE_H
BinaryOpTreeNode is a derived node of TreeNodeBase, which handles the binary calc.
Definition BinaryOpTreeNode.h:11
double evaluate() const override
evaluate the expressions
Definition BinaryOpTreeNode.cpp:27
Tree Node is expected to be like this!
Definition TreeNodeBase.h:7