Skip to content

@graphty/cytoscape-extensions / index / SearchResult

Interface: SearchResult ​

Defined in: cytoscape-extensions/src/algorithms.ts:204

A walk from one root, in the shape of Cytoscape's bfs / dfs.

Properties ​

found ​

readonly found: CollectionReturnValue

Defined in: cytoscape-extensions/src/algorithms.ts:208

The goal node when it was reached, else empty.


path ​

readonly path: CollectionReturnValue

Defined in: cytoscape-extensions/src/algorithms.ts:206

The visited nodes in visit order, each after the tree edge that reached it.

Methods ​

depth() ​

depth(node): number | undefined

Defined in: cytoscape-extensions/src/algorithms.ts:213

Edges from the root along the walk's tree (the parent links): the shortest hop count for a breadth-first search, the tree depth for a depth-first search, which can be larger. Undefined when not visited.

Parameters ​

node ​

ElementRef

Returns ​

number | undefined


parent() ​

parent(node): NodeSingular | undefined

Defined in: cytoscape-extensions/src/algorithms.ts:215

The node this one was reached from; undefined for the root and unvisited nodes.

Parameters ​

node ​

ElementRef

Returns ​

NodeSingular | undefined