2using System.Threading.Tasks;
14 private IValue value =
null;
119 public string Name => this.name;
141 public override Task
FromXml(XmlElement Definition)
145 return base.FromXml(Definition);
154 if (this.value is
null)
157 throw new Exception(
"Argument already has a value defined.");
Root node of a simulation model
Defines an argument in an action.
void Register(IValue Value)
Registers a value for the argument.
override string LocalName
Local name of XML element defining contents of class.
Argument(ISimulationNode Parent, Model Model, string Name, string Value)
Defines an argument in an action.
Argument(ISimulationNode Parent, Model Model, string Name, System.DateTime Value)
Defines an argument in an action.
Argument(ISimulationNode Parent, Model Model, string Name, TimeSpan Value)
Defines an argument in an action.
Argument(ISimulationNode Parent, Model Model, string Name, Waher.Content.Duration Value)
Defines an argument in an action.
override Task FromXml(XmlElement Definition)
Sets properties and attributes of class in accordance with XML definition.
Argument(ISimulationNode Parent, Model Model, string Name, double Value)
Defines an argument in an action.
string Name
Name of variable within the scope of the event.
override ISimulationNode Create(ISimulationNode Parent, Model Model)
Creates a new instance of the node.
Argument(ISimulationNode Parent, Model Model, string Name, Waher.Script.Expression Value)
Defines an argument in an action.
Argument(ISimulationNode Parent, Model Model)
Defines an argument in an action.
Abstract base class for simulation nodes with children
void AddChild(ISimulationNode Child)
Adds a child node.
ISimulationNode Parent
Parent node in the simulation model.
Abstract base class for values
Helps with common XML-related tasks.
static string Attribute(XmlElement E, string Name)
Gets the value of an XML attribute.
Class managing a script expression.
Basic interface for simulator nodes. Implementing this interface allows classes with default contruct...
Interface for nodes holding a value node
Represents a duration value, as defined by the xsd:duration data type: http://www....