Skip to main content

exact_property

Function exact_property 

Source
pub fn exact_property(
    model: &Model,
    object: EntityId,
    set_name: Option<&str>,
    property_name: &str,
) -> Result<ExactResolution, ExactPropertyError>
Expand description

Resolve a property or quantity by exact set and property name.

Single, enumerated, list, bounded, table and reference values resolve, the last five as composite ExactValues. An IfcComplexProperty or IfcPhysicalComplexQuantity resolves as ExactValue::Complex: present, with no value type (#208).

A predefined property set (IfcDoorLiningProperties and the like) is searched too: its members are the attributes its entity declares, by schema name (LiningDepth), and its set name is its Name, or its entity name (IfcDoorLiningProperties) when it states none. A door with one IfcDoorPanelProperties per leaf is ambiguous here; list such sets with exact_predefined_sets.

The model is resolved against the single release its FILE_SCHEMA declares, IFC2X3, IFC4 or IFC4X3 (see exact_schema); every domain, select and slot count is that release’s. With set_name == None, all assigned sets are searched. Occurrence values override matching inherited values at property level. To enumerate every property instead of naming one, use exact_properties.

object may also be an IfcTypeObject of the release (an IfcWallType, an IFC2X3 IfcDoorStyle, …). Its own HasPropertySets are then searched, with the validation an occurrence’s inherited type sets get, and a result carries ExactSource::Type with object’s id. $ states no sets, a proven absence; an empty list is refused as for an inherited type. A type object named in an IfcRelDefinesByProperties is refused (ExactPropertyError::InvalidOccurrenceTarget), never ignored.

Quantity sets are searched like property sets, as buildingSMART IDS treats a quantity as a property: Qto_WallBaseQuantities.Length resolves to the IfcQuantityLength of that name. A property set and a quantity set of the same matching name on one source are ambiguous and refused. WHERE rules such as LengthValue >= 0 are not evaluated; the value is the file’s.

§Errors

Any ExactPropertyError: the answer is refused rather than guessed whenever the evidence is incomplete, ambiguous, or foreign to the declared release.