| 1 | <?php |
||
| 7 | abstract class OperationNode extends Node |
||
| 8 | { |
||
| 9 | protected string $operator; |
||
|
|
|||
| 10 | protected Node $firstOperand; |
||
| 11 | protected Node $secondOperand; |
||
| 12 | |||
| 13 | public function __construct(string $operator, Node $firstOperand, Node $secondOperand) |
||
| 14 | { |
||
| 15 | $this->operator = $operator; |
||
| 16 | $this->firstOperand = $firstOperand; |
||
| 17 | $this->secondOperand = $secondOperand; |
||
| 18 | } |
||
| 19 | } |
||
| 20 |