Skip to main content

create_quantity_with

Function create_quantity_with 

Source
pub fn create_quantity_with(
    tx: &mut Transaction,
    model: &Model,
    kind: QuantityKind,
    name: &str,
    value: f64,
    extras: QuantityExtras<'_>,
) -> Result<EntityId, PropertyError>
Expand description

Stage a simple quantity with its optional attributes, in model’s release.

§The record has the release’s layout

Attributes are placed by name in the declared release’s table. IFC4 and IFC4X3 quantities have five attributes (Name, Description, Unit, the value, Formula); IFC2X3 ones have four, with no Formula. A model without FILE_SCHEMA binds IFC4. The value is written bare (IFCQUANTITYAREA('A',$,$,12.5,$)), since its declared type is a defined measure and not a SELECT.

§Errors

Nothing is staged on an error: