Example #1
0
 /// <summary>
 /// The attribute value.
 /// </summary>
 /// <param name="element">
 /// The element.
 /// </param>
 /// <param name="attributeName">
 /// The attribute name.
 /// </param>
 /// <returns>
 /// The <see cref="string"/>.
 /// </returns>
 public static string AttributeValue(this XElement element, string attributeName)
 {
     Assert.ArgumentNotNull(element, "element");
       return element.AttributeValue(attributeName, string.Empty);
 }
 /// <summary>
 /// 
 /// </summary>
 /// <param name="xElem"></param>
 /// <param name="attribute"></param>
 /// <returns></returns>
 public static string AttributeValue(this XElement xElem, string attribute)
 {
     return xElem.AttributeValue(attribute, string.Empty);
 }
 /// <summary>
 /// Returns whether the attribute whose name is contained in <see cref="XsiNilName"/> exists and contains the string "true".
 /// </summary>
 /// <param name="element"></param>
 /// <returns></returns>
 public static bool XsiNil(this XElement element)
 {
     return element.AttributeValue(XsiNilName) == "true";
 }