XElementExtensions.HasElementValue method
Version 1.1.28
.NET Framework 4.8
Namespace | Skybrud.Essentials.Xml.Extensions |
---|---|
Assembly | Skybrud.Essentials.dll |
HasElementValue(XElement, XName)
Extension method
Gets whether the first element matching the specified name
has a value.
public static bool HasElementValue(this XElement element, XName name)
Parameters
Returns
true
if an element was found and has a value; otherwise false
.
HasElementValue(XElement, string)
Extension method
Gets whether the first element matching the specified XPath expression
has a value.
public static bool HasElementValue(this XElement element, string expression)
Returns
true
if an element was found and has a value; otherwise false
.
HasElementValue(XElement, string, IXmlNamespaceResolver)
Extension method
Gets whether the first element matching the specified XPath expression
has a value.
public static bool HasElementValue(this XElement element, string expression, IXmlNamespaceResolver resolver)
Parameters
expression
String
The XPath expression.
resolver
IXmlNamespaceResolver
An instance of IXmlNamespaceResolver for the namespace prefixes in the XPath expression.
Returns
true
if an element was found and has a value; otherwise false
.