Ejemplo n.º 1
0
        internal static CT_ExternalBook Parse(XElement node, XmlNamespaceManager namespaceManager)
        {
            if (node == null)
            {
                return(null);
            }
            CT_ExternalBook ctObj = new CT_ExternalBook();

            ctObj.idField = XmlHelper.ReadString(node.Attribute((XNamespace)namespaceManager.LookupNamespace("r") + "id"));
            foreach (XElement childNode in node.ChildElements())
            {
                if (childNode.Name.LocalName == "sheetNames")
                {
                    ctObj.sheetNamesField = CT_ExternalSheetNames.Parse(childNode, namespaceManager);
                }
                else if (childNode.Name.LocalName == "definedNames")
                {
                    ctObj.definedNamesField = CT_ExternalDefinedNames.Parse(childNode, namespaceManager);
                }
                else if (childNode.Name.LocalName == "sheetDataSet")
                {
                    ctObj.sheetDataSetField = CT_ExternalSheetDataSet.Parse(childNode, namespaceManager);
                }
            }

            return(ctObj);
        }
Ejemplo n.º 2
0
        internal static CT_ExternalSheetNames Parse(XElement node, XmlNamespaceManager namespaceManager)
        {
            CT_ExternalSheetNames ctObj = new CT_ExternalSheetNames();

            foreach (XElement childNode in node.ChildElements())
            {
                ctObj.sheetNameField.Add(CT_ExternalSheetName.Parse(childNode, namespaceManager));
            }
            return(ctObj);
        }