Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ MoveToAttribute()

override bool System.Xml.DocumentXPathNavigator.MoveToAttribute ( string localName,
string namespaceURI )
inlinevirtual

Reimplemented from System.Xml.XPath.XPathNavigator.

Definition at line 294 of file DocumentXPathNavigator.cs.

295 {
296 if (_source is XmlElement { HasAttributes: not false } xmlElement)
297 {
298 XmlAttributeCollection attributes = xmlElement.Attributes;
299 for (int i = 0; i < attributes.Count; i++)
300 {
301 XmlAttribute xmlAttribute = attributes[i];
302 if (xmlAttribute.LocalName == localName && xmlAttribute.NamespaceURI == namespaceURI)
303 {
304 if (!xmlAttribute.IsNamespace)
305 {
308 return true;
309 }
310 return false;
311 }
312 }
313 }
314 return false;
315 }

References System.Xml.DocumentXPathNavigator._attributeIndex, System.Xml.DocumentXPathNavigator._source, System.Xml.XmlAttributeCollection.Count, System.Xml.Dictionary, and System.Xml.DocumentXPathNavigator.HasAttributes.