IFClite TypeScript API
    Preparing search index...

    Interface WorkerParserOptions

    Browser-only exports for @ifc-lite/parser

    These exports use Vite-specific features (worker imports) and are only available in browser environments with bundlers that support them.

    Usage: import { WorkerParser } from '@ifc-lite/parser/browser';

    interface WorkerParserOptions {
        deferPropertyAtomIndex?: boolean;
        disableWorkerScan?: boolean;
        onDiagnostic?: (message: string) => void;
        onMemorySnapshot?: (snapshot: ParserMemorySnapshot) => void;
        onProgress?: (progress: { percent: number; phase: string }) => void;
        onScanReport?: (report: EntityScanReport) => void;
        onSpatialReady?: (partialStore: IfcDataStore) => void;
        preScannedEntityIndex?: PreScannedEntityIndex;
        signal?: AbortSignal;
        sourceFingerprint?: SharedArrayBuffer;
        trace?: LoadTrace;
        waitForEntityIndex?: boolean;
        wasmApi?: WasmScanApi;
        workerUrl?: string | URL;
        yieldIntervalMs?: number;
    }

    Hierarchy (View Summary)

    Index
    deferPropertyAtomIndex?: boolean

    Keep property-set containers in the primary index but defer indexing individual property/quantity atoms.

    disableWorkerScan?: boolean

    Skip worker-based entity scanning and stay in-process. Useful for huge buffers already loaded on the main thread.

    onDiagnostic?: (message: string) => void
    onMemorySnapshot?: (snapshot: ParserMemorySnapshot) => void

    Optional callback receiving the per-parse memory snapshot at completion.

    onProgress?: (progress: { percent: number; phase: string }) => void
    onScanReport?: (report: EntityScanReport) => void
    onSpatialReady?: (partialStore: IfcDataStore) => void

    Called when spatial hierarchy is ready, BEFORE property/association parsing completes. Use this to show the hierarchy panel early while the full parse finishes.

    preScannedEntityIndex?: PreScannedEntityIndex

    Pre-built entity index from another worker (typically the streaming geometry pre-pass). When supplied, parseColumnar skips both the worker-based and WASM scans and retains the numeric columns through entity categorization. Only records needed for metadata extraction materialize EntityRefs; every record remains addressable in the store.

    signal?: AbortSignal

    Cancel this parse. If already aborted when parseColumnar is called, the returned promise rejects immediately without spawning a worker. If aborted while the parse is in flight, only THIS request's worker is terminated and the promise rejects with signal.reason: a custom abort(reason) is passed through as-is, the default is an AbortError.

    sourceFingerprint?: SharedArrayBuffer

    Fresh per-request 16-byte prepass fingerprint cell; never awaited.

    trace?: LoadTrace

    The caller's load trace (#6979). Records parser.worker (spawn to settle) with the worker's own phase spans merged under it, plus the main-thread parser.hydrate / parser.hydratePartial. Absent or disabled: no-op.

    waitForEntityIndex?: boolean

    Tell the worker to wait for setEntityIndex before running its WASM scan. Enable when the streaming geometry pre-pass will hand over the entity index — saves a duplicate 6–10 s scan on huge files.

    wasmApi?: WasmScanApi
    workerUrl?: string | URL

    Override the worker URL. Default: bundler-resolved parser.worker.ts.

    yieldIntervalMs?: number

    Yield budget for large incremental parses. Higher values finish faster with longer main-thread slices.