Headless.XPathNavigableExtensions.HasAttribute C# (CSharp) Method

HasAttribute() public static method

Determines whether the specified navigable has the specified attribute.
public static HasAttribute ( this navigable, string name ) : bool
navigable this /// The navigable. ///
name string /// The name. ///
return bool
        public static bool HasAttribute(this IXPathNavigable navigable, string name)
        {
            var navigator = navigable.GetNavigator();

            var checkedFound = navigator.MoveToAttribute(name, string.Empty);

            return checkedFound;
        }