internal override void ParseXml(XmlElement xml)
{
base.ParseXml(xml);
foreach (XmlNode child in xml.ChildNodes)
{
string name = child.Name;
if (string.Compare(name, "Points") == 0)
Points = mDatabase.ParseXml<IfcCartesianPointList>(child as XmlElement);
else if (string.Compare(name, "Segments") == 0)
{
List<IfcSegmentIndexSelect> segs = new List<IfcSegmentIndexSelect>(child.ChildNodes.Count);
foreach(XmlNode node in child.ChildNodes)
{
List<int> ints = node.InnerText.Split(" ".ToCharArray()).ToList().ConvertAll(x => int.Parse(x));
if (string.Compare("IfcLineIndex-wrapper", node.Name) == 0)
segs.Add(new IfcLineIndex(ints));
else
segs.Add(new IfcArcIndex(ints[0], ints[1], ints[2]));
}
Segments = segs;
}
}
if (xml.HasAttribute("SelfIntersect"))
mSelfIntersect = bool.Parse(xml.Attributes["SelfIntersect"].Value) ? IfcLogicalEnum.TRUE : IfcLogicalEnum.FALSE;
}