* Find the shortest path between two nodes * * @param fromId - Starting node ID * @param toId - Target node ID * @param edgeKinds - Edge types to consider (all if empty) * @returns Array of nodes and edges forming the path, or null if no path exists
(
fromId: string,
toId: string,
edgeKinds?: Edge['kind'][]
)
| 3162 | * @returns Array of nodes and edges forming the path, or null if no path exists |
| 3163 | */ |
| 3164 | findPath( |
| 3165 | fromId: string, |
| 3166 | toId: string, |
| 3167 | edgeKinds?: Edge['kind'][] |
| 3168 | ): Array<{ node: Node; edge: Edge | null }> | null { |
| 3169 | return this.traverser.findPath(fromId, toId, edgeKinds); |
| 3170 | } |
| 3171 | |
| 3172 | /** |
| 3173 | * Get ancestors of a node in the containment hierarchy |