AngleSharp by AngleSharp

<PackageReference Include="AngleSharp" Version="1.3.0" />

.NET API 960,512 bytes

 SelectorExtensions

public static class SelectorExtensions
Defines a set of extension methods involving selectors.
public static IEnumerable<IElement> Children(this IEnumerable<IElement> elements, string selectorText = null)

Gets the children of the provided elements. Optionally uses a CSS selector to filter the results.

public static IEnumerable<IElement> Children(this IEnumerable<IElement> elements, ISelector selector = null)

Gets the children of the provided elements. Optionally uses a CSS selector to filter the results.

public static T Eq<T>(this IEnumerable<T> elements, int index) where T : IElement

Reduces the elements to the one at the given index, if any.

public static IEnumerable<T> Even<T>(this IEnumerable<T> elements) where T : IElement

Reduces the elements to the ones with even index.

public static IEnumerable<T> Filter<T>(this IEnumerable<T> elements, string selectorText) where T : IElement

Keeps elements that are matched by the provided selector.

public static IEnumerable<T> Gt<T>(this IEnumerable<T> elements, int index) where T : IElement

Reduces the elements to the ones above the given index.

public static IEnumerable<T> Is<T>(this IEnumerable<T> elements, ISelector selector) where T : IElement

Keeps elements that are matched by the provided selector.

public static IEnumerable<T> Lt<T>(this IEnumerable<T> elements, int index) where T : IElement

Reduces the elements to the ones below the given index.

public static IEnumerable<IElement> Next(this IEnumerable<IElement> elements, string selectorText = null)

Gets the following siblings of the provided elements. Optionally uses a CSS selector to filter the results.

public static IEnumerable<IElement> Next(this IEnumerable<IElement> elements, ISelector selector = null)

Gets the following siblings of the provided elements. Optionally uses a CSS selector to filter the results.

public static IEnumerable<T> Not<T>(this IEnumerable<T> elements, string selectorText) where T : IElement

Keeps elements that are not matched by the provided selector.

public static IEnumerable<T> Not<T>(this IEnumerable<T> elements, ISelector selector) where T : IElement

Keeps elements that are not matched by the provided selector.

public static IEnumerable<T> Odd<T>(this IEnumerable<T> elements) where T : IElement

Reduces the elements to the ones with odd index.

public static IEnumerable<IElement> Parent(this IEnumerable<IElement> elements, string selectorText = null)

Gets the parents of the provided elements. Optionally uses a CSS selector to filter the results.

public static IEnumerable<IElement> Parent(this IEnumerable<IElement> elements, ISelector selector = null)

Gets the parents of the provided elements. Optionally uses a CSS selector to filter the results.

public static IEnumerable<IElement> Previous(this IEnumerable<IElement> elements, string selectorText = null)

Gets the preceding siblings of the provided elements. Optionally uses a CSS selector to filter the results.

public static IEnumerable<IElement> Previous(this IEnumerable<IElement> elements, ISelector selector = null)

Gets the preceding siblings of the provided elements. Optionally uses a CSS selector to filter the results.

public static IEnumerable<IElement> Siblings(this IEnumerable<IElement> elements, string selectorText = null)

Gets the siblings of the provided elements. Optionally uses a CSS selector to filter the results.

public static IEnumerable<IElement> Siblings(this IEnumerable<IElement> elements, ISelector selector = null)

Gets the siblings of the provided elements. Optionally uses a CSS selector to filter the results.