graphtransliterator-ts


graphtransliterator-ts / childrenOf

Function: childrenOf()

childrenOf<T, N, E>(graph, parentId): number[]

Defined in: Graphs.ts:175

Returns an ordered array of children node identifiers connected directly from a parent node. Achieves high performance by leveraging the pre-compiled O(1) successors lookup index.

Ordering: Sorted ascending by numeric NodeId values.

Type Parameters

T

T

N

N

E

E

Parameters

graph

DirectedGraph<T, N, E>

parentId

number

Returns

number[]