From 1e09caaa2980fe901453b4b90985967a51157887 Mon Sep 17 00:00:00 2001 From: rtk0c Date: Mon, 19 Apr 2021 14:00:47 -0700 Subject: Split workflow into multiple files, fix unity build --- core/src/Model/Workflow/Nodes/NumericNodes.hpp | 41 ++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 core/src/Model/Workflow/Nodes/NumericNodes.hpp (limited to 'core/src/Model/Workflow/Nodes/NumericNodes.hpp') diff --git a/core/src/Model/Workflow/Nodes/NumericNodes.hpp b/core/src/Model/Workflow/Nodes/NumericNodes.hpp new file mode 100644 index 0000000..32610f6 --- /dev/null +++ b/core/src/Model/Workflow/Nodes/NumericNodes.hpp @@ -0,0 +1,41 @@ +#pragma once + +#include "Model/Workflow/Workflow.hpp" + +#include +#include +#include +#include + +class NumericOperationNode : public WorkflowNode { +public: + enum OperationType { + Addition, + Subtraction, + Multiplication, + Division, + + InvalidType, + TypeCount = InvalidType, + }; + +private: + OperationType mType; + +public: + static Kind OperationTypeToNodeKind(OperationType type); + static OperationType NodeKindToOperationType(Kind kind); + static bool IsInstance(const WorkflowNode* node); + NumericOperationNode(OperationType type); + + virtual void Evaluate(WorkflowEvaluationContext& ctx) override; +}; + +class NumericExpressionNode : public WorkflowNode { +public: + static bool IsInstance(const WorkflowNode* node); + NumericExpressionNode(); + + // TODO + virtual void Evaluate(WorkflowEvaluationContext& ctx) override; +}; \ No newline at end of file -- cgit v1.2.3-70-g09d2