コード例 #1
0
        /// <summary>
        /// Creates an XmlSignificantWhitespace node.
        /// </summary>
        /// <param name="data">The string must contain only the following characters &#20; &#10; &#13; and &#9;</param>
        /// <returns>A new XmlSignificantWhitespace node.</returns>
        public override XmlSignificantWhitespace CreateSignificantWhitespace(string data)
        {
            LineInfoSignificantWhitespace sw = new LineInfoSignificantWhitespace(data, this);
            IXmlLineInfo lineInfo            = this.reader as IXmlLineInfo;

            if (lineInfo != null && lineInfo.HasLineInfo())
            {
                sw.SetLineInfo(lineInfo.LineNumber, lineInfo.LinePosition);
            }
            return(sw);
        }
コード例 #2
0
 /// <summary>
 /// Creates an XmlSignificantWhitespace node.
 /// </summary>
 /// <param name="data">The string must contain only the following characters &#20; &#10; &#13; and &#9;</param>
 /// <returns>A new XmlSignificantWhitespace node.</returns>
 public override XmlSignificantWhitespace CreateSignificantWhitespace(string data)
 {
     LineInfoSignificantWhitespace sw = new LineInfoSignificantWhitespace(data, this);
     IXmlLineInfo lineInfo = this.reader as IXmlLineInfo;
     if (lineInfo != null && lineInfo.HasLineInfo())
     {
         sw.SetLineInfo(lineInfo.LineNumber, lineInfo.LinePosition);
     }
     return sw;
 }