Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/rimbu/graph/custom/valued/implementation/empty.ts>ValuedGraphEmpty

Rimbu is a TypeScript library focused on immutable, performant, and type-safe collections and other tools.
Go to Latest
class ValuedGraphEmpty
implements ValuedGraphBase<N, V, Tp>
import { ValuedGraphEmpty } from "https://deno.land/x/rimbu@1.2.0/graph/custom/valued/implementation/empty.ts";

Constructors

new
ValuedGraphEmpty(isDirected: boolean, context: TpG["context"])

Properties

readonly
linkMap: TpG["linkMap"]

Methods

addNode(node: N): TpG["nonEmpty"]
addNodes(nodes: StreamSource<N>): WithGraphValues<Tp, N, V>["nonEmpty"]
connect(
node1: N,
node2: N,
value: V,
): TpG["nonEmpty"]
connectAll(links: StreamSource<WithGraphValues<Tp, N, V>["link"]>): WithGraphValues<Tp, N, V>["nonEmpty"]
getConnectionsFrom(): TpG["linkConnections"]
getValue<UN, O>(
node1: RelatedTo<N, UN>,
node2: RelatedTo<N, UN>,
otherwise?: OptLazy<O>,
): O
mapValues<V2>(): WithGraphValues<Tp, N, V2>["normal"]
modifyAt(
node1: N,
node2: N,
options: { ifNew?: OptLazyOr<V, Token>; ifExists?: (value: V, remove: Token) => V | Token; },
): WithGraphValues<Tp, N, V>["normal"]
toBuilder(): TpG["builder"]
toJSON(): ToJSON<any[]>
toString(): string