IFClite TypeScript API
    Preparing search index...

    Function isKnownType

    • Check if a type is a real IFC entity class in any bundled schema.

      Answers for the union of every bundled IFC schema (2X3 + 4 + 4X3), falling back to the parser's IFC4_ADD2_TC1 codegen pin — the same union-first, pin-second order as getInheritanceChain. Answering from the pin alone rejected roughly 251 perfectly valid classes: the IFC2X3 ones IFC4 dropped (IfcMove, IfcScheduleTimeControl, IfcSpaceProgram, …) and the IFC4X3 infrastructure ones it never had (IfcRoad, IfcSignal, IfcAlignment, …). That made @ifc-lite/sdk's addEntity refuse to author them at all (#2003).

      Still a real guard, not a pass-through: a typo (IfcWal), a vendor extension and an EXPRESS defined type (IfcLengthMeasure, IfcArcIndex) are all rejected. So are Object.prototype member names (constructor, toString, __proto__, ...): the union lookup is a Map, and the pin fallback's own-property test — added in #3063/#3069, replacing an in that walked the prototype chain and answered true for every one of them — keeps the second lookup from re-admitting them. Callers of this predicate (ofType(), addEntity) rely on that; the guard is only as good as isKnownEntity.

      Known-ness, not instantiability: abstract supertypes (IfcProduct, IfcRoot) answer true, as they always have — that is a different predicate, isInstantiable, and it belongs at the authoring boundary, not in a name-registry check (#2035).

      Parameters

      • type: string

      Returns boolean