Example #1
0
        public static XDom LoadUri(string fileUri, Encoding encoding)
        {
            XDom temp = new XDom();
            temp.Load(fileUri, encoding);

            return temp;
        }
Example #2
0
        public static XDom LoadOps(string opsXml)
        {
            XDom temp = new XDom();
            temp.Add(opsXml);

            return temp;
        }
Example #3
0
        public static XDom LoadOps(string opsXml)
        {
            XDom temp = new XDom();

            temp.Add(opsXml);

            return(temp);
        }
Example #4
0
        public static XDom LoadUri(string fileUri, Encoding encoding)
        {
            XDom temp = new XDom();

            temp.Load(fileUri, encoding);

            return(temp);
        }
Example #5
0
        /// <summary>
        /// 去除<![CDATA[]]>代码
        /// </summary>
        /// <returns></returns>
        public XItem CDATA()
        {
            if (_IsCDATA == false)
            {
                this.Text = XDom.CDATA(this.Text);
            }

            return(this);
        }
Example #6
0
        public static XDom LoadXml(XmlNode node)
        {
            XDom temp = new XDom();

            foreach(XmlAttribute a in node.Attributes)
                temp.Add(a.Name, a.Value);

            foreach (XmlNode n in node.ChildNodes)
                temp.Add(n.Name, n.InnerXml);

            return temp;
        }
Example #7
0
        public XItem Set(XDom data)
        {
            if (textWt == null)
            {
                textWt = new StringBuilder(this.Text);
            }

            foreach (XItem item in data)
            {
                textWt.Replace("{" + item.Name + "}", item.Text);
            }

            return(this);
        }
Example #8
0
        public static XDom LoadXml(XmlNode node)
        {
            XDom temp = new XDom();

            foreach (XmlAttribute a in node.Attributes)
            {
                temp.Add(a.Name, a.Value);
            }

            foreach (XmlNode n in node.ChildNodes)
            {
                temp.Add(n.Name, n.InnerXml);
            }

            return(temp);
        }
Example #9
0
 public static XDom LoadXml(string xml, bool isDoc)
 {
     return(LoadXml(XDom.ParseXml(xml, isDoc)));
 }
Example #10
0
File: XItem.cs Project: noear/Weed3
        public XItem Set(XDom data)
        {
            if (textWt == null)
                textWt = new StringBuilder(this.Text);

            foreach (XItem item in data)
                textWt.Replace("{" + item.Name + "}", item.Text);

            return this;
        }