SelectFirstXPath(Visual, String) Method

Definition

Assembly HeadlessTestingFramework.dll

Selects the first node using XPath expression.

public static T? SelectFirstXPath<T>(this Visual root, string xpath)
    where T : class

Type parameters

T
The type to cast result to.

Parameters

root
Avalonia.Visual

The root visual.

xpath
String

The XPath expression.

Returns

{T}
The first matching node, or null.