Пример #1
0
        /// <summary>See <see cref="IMatchedNodes.IsMatched"/>.</summary>
        public bool IsMatched(System.Xml.XPath.XPathNavigator node)
        {
            IXmlLineInfo info = (IXmlLineInfo)node;

            if (!_matched.ContainsKey(info.LineNumber))
            {
                return(false);
            }

            Int32Collection pos = (Int32Collection)_matched[info.LineNumber];

            if (!pos.Contains(info.LinePosition))
            {
                return(false);
            }

            return(true);
        }
Пример #2
0
 /// <summary>See <see cref="IMatchedNodes.IsMatched"/>.</summary>
 public bool IsMatched(XPathNavigator node)
 {
     return(_matched.Contains(((IHasXmlNode)node).GetNode().GetHashCode()));
 }