UNPKG

graph-builder

Version:

A graph builder library for modeling abstract graph structures.

19 lines (18 loc) 712 B
import { GraphConnections } from "./GraphConnections"; /** * An implementation of {@link GraphConnections} for undirected graphs. */ export declare class UndirectedGraphConnections<N, V> implements GraphConnections<N, V> { private adjacentNodeValues; private constructor(); static of<N, V>(): UndirectedGraphConnections<N, V>; static ofImmutable<N, V>(adjacentNodeValues: Map<N, V>): UndirectedGraphConnections<N, V>; adjacentNodes(): Set<N>; predecessors(): Set<N>; successors(): Set<N>; value(node: N): V; removePredecessor(node: N): void; removeSuccessor(node: N): V; addPredecessor(node: N, value: V): void; addSuccessor(node: N, value: V): V | undefined; }