2using System.Collections.Generic;
4using System.Threading.Tasks;
54 public override Task
FromXml(XmlElement Definition)
58 return Task.CompletedTask;
68 DateTime Now = DateTime.Now;
69 DateTime TP = Now + this.duration;
70 TimeSpan TS = TP - Now;
72 if (TS > TimeSpan.Zero)
84 public override void ExportPlantUml(StreamWriter Output,
int Indentation,
char QuoteChar)
86 Indent(Output, Indentation);
87 Output.Write(
":Delay(");
89 Values.Duration.ExportText(this.duration, Output);
91 Output.WriteLine(
");");
Root node of a simulation model
Abstract base class for activity nodes
Represents a delay in an activity.
override ISimulationNode Create(ISimulationNode Parent, Model Model)
Creates a new instance of the node.
override void ExportPlantUml(StreamWriter Output, int Indentation, char QuoteChar)
Exports PlantUML
override Task FromXml(XmlElement Definition)
Sets properties and attributes of class in accordance with XML definition.
Delay(ISimulationNode Parent, Model Model)
Represents a delay in an activity.
override async Task< LinkedListNode< IActivityNode > > Execute(Variables Variables)
Executes a node.
override string LocalName
Local name of XML element defining contents of class.
static void Indent(StreamWriter Output, int Indentation)
Adds indentation to the current row.
Helps with common XML-related tasks.
static string Attribute(XmlElement E, string Name)
Gets the value of an XML attribute.
Basic interface for simulator nodes. Implementing this interface allows classes with default contruct...
ISimulationNode Parent
Parent node in the simulation model.
Represents a duration value, as defined by the xsd:duration data type: http://www....
static readonly Duration Zero
Zero value