Skip to content

spatial-monorepo


spatial-monorepo / wayfinding/src / getFloorConnectivityGraph

Function: getFloorConnectivityGraph()

getFloorConnectivityGraph(archive, opts?): FloorConnectivityGraph

Defined in: packages/wayfinding/src/grid-multifloor.ts:159

Returns the cached FloorConnectivityGraph for archive (and the resolved portalProximityM), building (and caching) it on first use. The primary cache key is the archive object's identity: as long as callers treat an IMDFArchive as immutable and construct a new object on mutation (the existing pattern elsewhere in this package — the worker's buildGraph/buildSearchIndex are explicit rebuild calls, not auto-invalidated), this never goes stale. Call invalidateFloorConnectivityCache explicitly if a caller ever mutates an archive object in place instead of replacing it.

Parameters

archive

IMDFArchive

opts?

FloorConnectivityOptions = {}

Returns

FloorConnectivityGraph

Released under commercial licensing.