MrKWatkins.Ast Help

Children<TNode>.SingleOfType Method

Definition

Returns the only node in the collection of the specified type. Throws if there is not exactly one node in the collection of the specified type.

public TChild SingleOfType<TChild>() where TChild : TNode;

Type Parameters

Name

Description

TChild

The type of the node to return.

Returns

TChild

The single node in the collection of type TChild.

Last modified: 09 September 2024