HtmlAgilityPack.HtmlNodeNavigator.MoveToAttribute C# (CSharp) Méthode

MoveToAttribute() public méthode

Moves to the HTML attribute with matching LocalName and NamespaceURI.
public MoveToAttribute ( string localName, string namespaceURI ) : bool
localName string The local name of the HTML attribute.
namespaceURI string The namespace URI of the attribute. Unsupported with the HtmlNavigator implementation.
Résultat bool
        public override bool MoveToAttribute(string localName, string namespaceURI)
        {
            InternalTrace("localName=" + localName + ", namespaceURI=" + namespaceURI);
            int index = _currentnode.Attributes.GetAttributeIndex(localName);
            if (index == -1)
            {
                InternalTrace(">false");
                return false;
            }
            _attindex = index;
            InternalTrace(">true");
            return true;
        }