Table of Contents

Struct SqlNodeAncestors

Namespace
LfrlAnvil.Sql.Internal
Assembly
LfrlAnvil.Sql.Core.dll

Represents a stack of SqlNodeBase ancestor nodes.

public readonly struct SqlNodeAncestors
Inherited Members

Properties

Count

Number of ancestors.

public int Count { get; }

Property Value

int

this[int]

Gets an ancestor node at the provided 0-base index in this stack.

public SqlNodeBase this[int index] { get; }

Parameters

index int

0-based position of the ancestor node to get.

Property Value

SqlNodeBase

Exceptions

IndexOutOfRangeException

When index is out of bounds.

Methods

FindIndex(SqlNodeBase)

Attempts to find a 0-based index of the provided node in this stack.

[Pure]
public int FindIndex(SqlNodeBase node)

Parameters

node SqlNodeBase

Ancestor node to find.

Returns

int

0-based index of the provided node if it exists in this stack, otherwise -1.