Skip to main content

ModelProduct

Read-only view of an IFC product (element) in a building model.

This is the shared interface between the browser (@twinfinity/core) and server/Node.js (@twinfinity/t8-client-model) contexts, allowing business logic to be written once and consumed from both.

Implemented by

Index

Properties

readonlyaggregates

aggregates: readonly ModelProduct[]

Products related via IfcRelAggregates (decomposition). Empty when hasStructuredRelationships is false.

readonlychildren

children: Iterable<ModelProduct, any, any>

All child products regardless of relationship type.

readonlyclass

Parsed class with category information. Reference equality can be used for comparison.

readonlyclassName

className: string

Full IFC class name including prefix (e.g. 'IfcWall', 'IfcDoor').

readonlycomputedPropertySets

computedPropertySets: Record<string, T8PropertySet<T8Unit>>

Computed property sets added by Twinfinity processing.

readonlycontains

contains: readonly ModelProduct[]

Products related via IfcRelContainedInSpatialStructure (spatial containment). Empty when hasStructuredRelationships is false.

readonlydata

data: Record<string, string | number | boolean>

Product-level scalar data values (e.g. operationType, objectPlacement).

optionalreadonlydescription

description?: string

optionalreadonlyfacility

facility?: ModelProduct

The IfcBuilding (or IfcFacility) ancestor of this product.

optionalreadonlyfacilityPart

facilityPart?: ModelProduct

The IfcBuildingStorey (or IfcFacilityPart) ancestor of this product.

readonlyglobalId

globalId: string

IFC GlobalId (GUID), unique across all models.

readonlyhasGeometry

hasGeometry: boolean

True if this product has at least one mesh with geometry data.

readonlyhasStructuredRelationships

hasStructuredRelationships: boolean

True when aggregates and contains carry structured IFC relationship data (IfcRelAggregates / IfcRelContainedInSpatialStructure). When false, only children is populated.

readonlylocalId

localId: number

Numerical identifier, unique within a single model.

readonlymeshes

meshes: readonly ModelMesh[]

Geometry meshes belonging to this product.

optionalreadonlyname

name?: string

optionalreadonlyparent

parent?: ModelProduct

Closest parent in the spatial/aggregation hierarchy.

readonlypropertySets

propertySets: Record<string, T8PropertySet<T8Unit>>

IFC property sets (e.g. Pset_WallCommon).

readonlyquantitySets

quantitySets: Record<string, T8QuantitySet<T8Unit>>

IFC quantity sets (e.g. Qto_WallBaseQuantities).

optionalreadonlysite

The IfcSite ancestor of this product.

optionalreadonlytype

The entity type definition this product is an instance of (e.g. an IfcWallType).