Пример #1
0
 /// <summary>
 /// Constructor - create a material given an XPathNavigator positioned
 /// at a node in an XPathDocument which describes this material.
 /// </summary>
 /// <param name="navigator">The XPathNavigator to use</param>
 public Material(XPathNavigator navigator)
 {
     navigator.MoveToChild("name", "");
     this.name = navigator.Value;
     navigator.MoveToNext();
     do
     {
         XPathNavigator clone = navigator.Clone();
         clone.MoveToFirstChild();
         double temp = clone.ValueAsDouble;
         clone.MoveToNext();
         double            conductivity = clone.ValueAsDouble;
         PropertyDataPoint point        = new PropertyDataPoint(temp, conductivity);
         thermalConductivityData.Add(point);
     } while (navigator.MoveToNext());
 }
Пример #2
0
 /// <summary>
 /// Constructor - create a cooler given an XPathNavigator positioned
 /// at a node in an XPathDocument which describes this cooler.
 /// </summary>
 /// <param name="navigator">The XPathNavigator to use</param>
 public Cooler(XPathNavigator navigator)
 {
     navigator.MoveToChild("name", "");
     this.name = navigator.Value;
     navigator.MoveToNext();
     do
     {
         XPathNavigator clone = navigator.Clone();
         clone.MoveToFirstChild();
         double temp = clone.ValueAsDouble;
         clone.MoveToNext();
         double            coolingPower = clone.ValueAsDouble;
         PropertyDataPoint point        = new PropertyDataPoint(temp, coolingPower);
         coolingPowerData.Add(point);
     } while (navigator.MoveToNext());
 }