AllPairsResult<E>Result of an all-pairs shortest path computation.
When to use
Use when storing or passing around the complete output of floydWarshall so
callers can look up shortest distances, node paths, and edge data for any
source and target node pair.
Details
Contains distance, node-path, and edge-data maps keyed by source and target node indices.
export interface interface AllPairsResult<E>Result of an all-pairs shortest path computation.
When to use
Use when storing or passing around the complete output of floydWarshall so
callers can look up shortest distances, node paths, and edge data for any
source and target node pair.
Details
Contains distance, node-path, and edge-data maps keyed by source and target
node indices.
AllPairsResult<function (type parameter) E in AllPairsResult<E>E> {
readonly AllPairsResult<E>.distances: Map<NodeIndex, Map<NodeIndex, number>>distances: interface Map<K, V>Map<type NodeIndex = numberNode index for node identification using plain numbers.
When to use
Use when storing or passing the stable identifier of a graph node between
Graph operations.
Details
addNode allocates node identifiers from the graph's next node index.
Gotchas
A NodeIndex is an identifier, not an array offset. Removed node identifiers
are not reused.
NodeIndex, interface Map<K, V>Map<type NodeIndex = numberNode index for node identification using plain numbers.
When to use
Use when storing or passing the stable identifier of a graph node between
Graph operations.
Details
addNode allocates node identifiers from the graph's next node index.
Gotchas
A NodeIndex is an identifier, not an array offset. Removed node identifiers
are not reused.
NodeIndex, number>>
readonly AllPairsResult<E>.paths: Map<NodeIndex, Map<NodeIndex, Array<NodeIndex> | null>>paths: interface Map<K, V>Map<type NodeIndex = numberNode index for node identification using plain numbers.
When to use
Use when storing or passing the stable identifier of a graph node between
Graph operations.
Details
addNode allocates node identifiers from the graph's next node index.
Gotchas
A NodeIndex is an identifier, not an array offset. Removed node identifiers
are not reused.
NodeIndex, interface Map<K, V>Map<type NodeIndex = numberNode index for node identification using plain numbers.
When to use
Use when storing or passing the stable identifier of a graph node between
Graph operations.
Details
addNode allocates node identifiers from the graph's next node index.
Gotchas
A NodeIndex is an identifier, not an array offset. Removed node identifiers
are not reused.
NodeIndex, interface Array<T>Array<type NodeIndex = numberNode index for node identification using plain numbers.
When to use
Use when storing or passing the stable identifier of a graph node between
Graph operations.
Details
addNode allocates node identifiers from the graph's next node index.
Gotchas
A NodeIndex is an identifier, not an array offset. Removed node identifiers
are not reused.
NodeIndex> | null>>
readonly AllPairsResult<E>.costs: Map<NodeIndex, Map<NodeIndex, Array<E>>>costs: interface Map<K, V>Map<type NodeIndex = numberNode index for node identification using plain numbers.
When to use
Use when storing or passing the stable identifier of a graph node between
Graph operations.
Details
addNode allocates node identifiers from the graph's next node index.
Gotchas
A NodeIndex is an identifier, not an array offset. Removed node identifiers
are not reused.
NodeIndex, interface Map<K, V>Map<type NodeIndex = numberNode index for node identification using plain numbers.
When to use
Use when storing or passing the stable identifier of a graph node between
Graph operations.
Details
addNode allocates node identifiers from the graph's next node index.
Gotchas
A NodeIndex is an identifier, not an array offset. Removed node identifiers
are not reused.
NodeIndex, interface Array<T>Array<function (type parameter) E in AllPairsResult<E>E>>>
}