first commit

This commit is contained in:
Zeeshaun
2026-03-11 11:18:25 -05:00
commit f3cb730f3b
472 changed files with 53651 additions and 0 deletions
@@ -0,0 +1,34 @@
using System.Xml;
using System.Xml.Linq;
using System.Xml.XPath;
namespace CRIF.ACTion.Common.Parsers
{
public static class XElementExtensions
{
/*
Using XPathSelectElement on an XElement starts with the XElement's parent XDocument,
unless you convert the XElement itself to an XDocument
*/
public static XElement XElementXPathSelectElement(this XElement node, string expression)
{
return (new XDocument(node)).XPathSelectElement(expression);
}
public static XElement XElementXPathSelectElement(this XNode node, string expression, IXmlNamespaceResolver resolver)
{
return (new XDocument(node)).XPathSelectElement(expression, resolver);
}
public static IEnumerable<XElement> XElementXPathSelectElements(this XElement node, string expression)
{
return (new XDocument(node)).XPathSelectElements(expression);
}
public static IEnumerable<XElement> XElementXPathSelectElements(this XElement node, string expression, IXmlNamespaceResolver resolver)
{
return (new XDocument(node)).XPathSelectElements(expression, resolver);
}
}
}