GeometryGym.Ifc.IfcGeometricRepresentationContext.SetXML C# (CSharp) Méthode

SetXML() private méthode

private SetXML ( XmlElement xml, BaseClassIfc host, HashSet processed ) : void
xml System.Xml.XmlElement
host BaseClassIfc
processed HashSet
Résultat void
        internal override void SetXML(XmlElement xml, BaseClassIfc host, HashSet<int> processed)
        {
            base.SetXML(xml, host, processed);
            if (this as IfcGeometricRepresentationSubContext == null)
            {
                xml.SetAttribute("CoordinateSpaceDimension", mCoordinateSpaceDimension.ToString());
                if (!double.IsNaN(mPrecision))
                    xml.SetAttribute("Precision", mPrecision.ToString());
                if (mWorldCoordinateSystem > 0)
                    xml.AppendChild(mDatabase[mWorldCoordinateSystem].GetXML(xml.OwnerDocument, "WorldCoordinateSystem", this, processed));
                if (mTrueNorth > 0)
                    xml.AppendChild(TrueNorth.GetXML(xml.OwnerDocument, "TrueNorth", this, processed));
            }
            if (mHasSubContexts.Count > 0)
            {
                XmlElement element = xml.OwnerDocument.CreateElement("HasSubContexts");
                foreach (IfcGeometricRepresentationSubContext sub in mHasSubContexts)
                    element.AppendChild(sub.GetXML(xml.OwnerDocument, "", this, processed));
                xml.AppendChild(element);
            }

            if (mHasCoordinateOperation != null)
                xml.AppendChild(HasCoordinateOperation.GetXML(xml.OwnerDocument, "HasCoordinateOperation", this, processed));
        }