V12: Deprecate XPath (#14372)
* Deprecate all outward facing methods that uses XPath * Add more obsolete messages --------- Co-authored-by: Zeegaan <nge@umbraco.dk>
This commit is contained in:
@@ -34,6 +34,7 @@ public static class XmlExtensions
|
||||
/// </para>
|
||||
/// <para>The XPath expression should reference variables as <c>$var</c>.</para>
|
||||
/// </remarks>
|
||||
[Obsolete("The current implementation of XPath is suboptimal and will be removed entirely in a future version. Scheduled for removal in v14")]
|
||||
public static XmlNodeList? SelectNodes(this XmlNode source, string expression, IEnumerable<XPathVariable>? variables)
|
||||
{
|
||||
XPathVariable[]? av = variables?.ToArray();
|
||||
@@ -56,6 +57,7 @@ public static class XmlExtensions
|
||||
/// </para>
|
||||
/// <para>The XPath expression should reference variables as <c>$var</c>.</para>
|
||||
/// </remarks>
|
||||
[Obsolete("The current implementation of XPath is suboptimal and will be removed entirely in a future version. Scheduled for removal in v14")]
|
||||
public static XmlNodeList? SelectNodes(this XmlNode source, XPathExpression expression, IEnumerable<XPathVariable>? variables)
|
||||
{
|
||||
XPathVariable[]? av = variables?.ToArray();
|
||||
@@ -78,6 +80,7 @@ public static class XmlExtensions
|
||||
/// </para>
|
||||
/// <para>The XPath expression should reference variables as <c>$var</c>.</para>
|
||||
/// </remarks>
|
||||
[Obsolete("The current implementation of XPath is suboptimal and will be removed entirely in a future version. Scheduled for removal in v14")]
|
||||
public static XmlNodeList? SelectNodes(this XmlNode source, string? expression, params XPathVariable[]? variables)
|
||||
{
|
||||
if (variables == null || variables.Length == 0 || variables[0] == null)
|
||||
@@ -105,6 +108,7 @@ public static class XmlExtensions
|
||||
/// </para>
|
||||
/// <para>The XPath expression should reference variables as <c>$var</c>.</para>
|
||||
/// </remarks>
|
||||
[Obsolete("The current implementation of XPath is suboptimal and will be removed entirely in a future version. Scheduled for removal in v14")]
|
||||
public static XmlNodeList SelectNodes(this XmlNode source, XPathExpression expression, params XPathVariable[]? variables)
|
||||
{
|
||||
if (variables == null || variables.Length == 0 || variables[0] == null)
|
||||
@@ -132,6 +136,7 @@ public static class XmlExtensions
|
||||
/// </para>
|
||||
/// <para>The XPath expression should reference variables as <c>$var</c>.</para>
|
||||
/// </remarks>
|
||||
[Obsolete("The current implementation of XPath is suboptimal and will be removed entirely in a future version. Scheduled for removal in v14")]
|
||||
public static XmlNode? SelectSingleNode(this XmlNode source, string expression, IEnumerable<XPathVariable>? variables)
|
||||
{
|
||||
XPathVariable[]? av = variables?.ToArray();
|
||||
@@ -154,6 +159,7 @@ public static class XmlExtensions
|
||||
/// </para>
|
||||
/// <para>The XPath expression should reference variables as <c>$var</c>.</para>
|
||||
/// </remarks>
|
||||
[Obsolete("The current implementation of XPath is suboptimal and will be removed entirely in a future version. Scheduled for removal in v14")]
|
||||
public static XmlNode? SelectSingleNode(this XmlNode source, XPathExpression expression, IEnumerable<XPathVariable>? variables)
|
||||
{
|
||||
XPathVariable[]? av = variables?.ToArray();
|
||||
@@ -176,6 +182,7 @@ public static class XmlExtensions
|
||||
/// </para>
|
||||
/// <para>The XPath expression should reference variables as <c>$var</c>.</para>
|
||||
/// </remarks>
|
||||
[Obsolete("The current implementation of XPath is suboptimal and will be removed entirely in a future version. Scheduled for removal in v14")]
|
||||
public static XmlNode? SelectSingleNode(this XmlNode source, string expression, params XPathVariable[]? variables)
|
||||
{
|
||||
if (variables == null || variables.Length == 0 || variables[0] == null)
|
||||
@@ -202,6 +209,7 @@ public static class XmlExtensions
|
||||
/// </para>
|
||||
/// <para>The XPath expression should reference variables as <c>$var</c>.</para>
|
||||
/// </remarks>
|
||||
[Obsolete("The current implementation of XPath is suboptimal and will be removed entirely in a future version. Scheduled for removal in v14")]
|
||||
public static XmlNode? SelectSingleNode(this XmlNode source, XPathExpression expression, params XPathVariable[]? variables)
|
||||
{
|
||||
if (variables == null || variables.Length == 0 || variables[0] == null)
|
||||
|
||||
Reference in New Issue
Block a user