IFClite TypeScript API
    Preparing search index...

    Function buildCSR

    • Build CSR (Compressed Sparse Row) using counting sort. O(n) instead of O(n log n) — crucial for 12M+ edges.

      Exported because the graph can be reconstructed from raw edge arrays (e.g. when merging or rebuilding a graph) without going through the RelationshipGraphBuilder mutation API. shadowedRelIds maps a pre-scatter edge index (in keys/values/types/relIds) to the extra IfcRel* ids collapsed into it; pass an empty Map when none.

      Parameters

      • n: number
      • keys: number[] | Uint32Array<ArrayBufferLike>
      • values: number[] | Uint32Array<ArrayBufferLike>
      • types: number[] | Uint16Array<ArrayBufferLike>
      • relIds: number[] | Uint32Array<ArrayBufferLike>
      • shadowedRelIds: Map<number, number[]>

      Returns RelationshipEdges