Antares Simulator
Power System Simulator
ParameterNode.h
1 #pragma once
2 
3 #include <string>
4 
5 #include <antares/expressions/nodes/Leaf.h>
6 #include <antares/study/system-model/variabilityType.h>
7 
8 namespace Antares::Expressions::Nodes
9 {
13 class ParameterNode final: public Leaf<std::string>
14 {
15 public:
16  explicit ParameterNode(const std::string& value,
17  Optimisation::VariabilityType time_index = Optimisation::
18  VariabilityType::VARYING_IN_TIME_AND_SCENARIO):
20  variability_(time_index)
21  {
22  }
23 
24  std::string name() const override
25  {
26  return "ParameterNode";
27  }
28 
29  Optimisation::VariabilityType variability() const
30  {
31  return variability_;
32  }
33 
34 private:
35  Optimisation::VariabilityType variability_;
36 };
37 } // namespace Antares::Expressions::Nodes
Represents a leaf node in a syntax tree.
Definition: Leaf.h:34
std::string value() const
Retrieves the value stored in the leaf node.
Definition: Leaf.h:51
Represents a parameter node in a syntax tree, storing a string value.
Definition: ParameterNode.h:14
VariabilityType
Represents the time and scenario variation of a value.
Definition: variabilityType.h:29