System.Xml.DocumentXPathNavigator.CheckAttributePosition C# (CSharp) Méthode

CheckAttributePosition() private static méthode

private static CheckAttributePosition ( XmlAttribute attribute, XmlAttributeCollection &attributes, int index ) : bool
attribute XmlAttribute
attributes XmlAttributeCollection
index int
Résultat bool
        private static bool CheckAttributePosition(XmlAttribute attribute, out XmlAttributeCollection attributes, int index) {
            XmlElement element = attribute.OwnerElement;
            if (element != null) {
                attributes = element.Attributes;
                if (index >= 0
                    && index < attributes.Count
                    && attribute == attributes[index]) {
                    return true;
                }
            }
            else {
                attributes = null;
            }
            return false;
        }