Neuron®
The Neuron® is the basis for the creation of open and secure federated networks for smart societies.
Loading...
Searching...
No Matches
Assembly.cs
1using System;
2using System.Threading.Tasks;
3using System.Xml;
5
7{
12 {
13 private string fileName;
14
21 : base(Parent, Model)
22 {
23 }
24
28 public override string LocalName => nameof(Assembly);
29
33 public string FileName => this.fileName;
34
42 {
43 return new Assembly(Parent, Model);
44 }
45
50 public override Task FromXml(XmlElement Definition)
51 {
52 this.fileName = XML.Attribute(Definition, "fileName");
53
54 return base.FromXml(Definition);
55 }
56 }
57}
Root node of a simulation model
Definition: Model.cs:49
Abstract base class for simulation nodes with children
ISimulationNode Parent
Parent node in the simulation model.
override Task FromXml(XmlElement Definition)
Sets properties and attributes of class in accordance with XML definition.
Definition: Assembly.cs:50
string FileName
Filename of assembly.
Definition: Assembly.cs:33
override string LocalName
Local name of XML element defining contents of class.
Definition: Assembly.cs:28
override ISimulationNode Create(ISimulationNode Parent, Model Model)
Creates a new instance of the node.
Definition: Assembly.cs:41
Assembly(ISimulationNode Parent, Model Model)
Assembly reference.
Definition: Assembly.cs:20
Helps with common XML-related tasks.
Definition: XML.cs:19
static string Attribute(XmlElement E, string Name)
Gets the value of an XML attribute.
Definition: XML.cs:914
Basic interface for simulator nodes. Implementing this interface allows classes with default contruct...