public static CT_HoleSize Parse(XElement node, XmlNamespaceManager namespaceManager) { if (node == null) { return(null); } CT_HoleSize ctObj = new CT_HoleSize(); if (node.Attribute("val") != null) { ctObj.val = XmlHelper.ReadByte(node.Attribute("val")); } return(ctObj); }
public static CT_DoughnutChart Parse(XElement node, XmlNamespaceManager namespaceManager) { if (node == null) { return(null); } CT_DoughnutChart ctObj = new CT_DoughnutChart(); ctObj.ser = new List <CT_PieSer>(); ctObj.extLst = new List <CT_Extension>(); foreach (XElement childNode in node.ChildElements()) { if (childNode.Name.LocalName == "varyColors") { ctObj.varyColors = CT_Boolean.Parse(childNode, namespaceManager); } else if (childNode.Name.LocalName == "dLbls") { ctObj.dLbls = CT_DLbls.Parse(childNode, namespaceManager); } else if (childNode.Name.LocalName == "firstSliceAng") { ctObj.firstSliceAng = CT_FirstSliceAng.Parse(childNode, namespaceManager); } else if (childNode.Name.LocalName == "holeSize") { ctObj.holeSize = CT_HoleSize.Parse(childNode, namespaceManager); } else if (childNode.Name.LocalName == "ser") { ctObj.ser.Add(CT_PieSer.Parse(childNode, namespaceManager)); } else if (childNode.Name.LocalName == "extLst") { ctObj.extLst.Add(CT_Extension.Parse(childNode, namespaceManager)); } } return(ctObj); }