#[non_exhaustive]pub struct PropertyTemplate {Show 14 fields
pub id: EntityId,
pub name: Option<Arc<str>>,
pub description: Option<Arc<str>>,
pub kind: PropertyTemplateKind,
pub template_type: Option<Arc<str>>,
pub primary_measure: Option<Arc<str>>,
pub secondary_measure: Option<Arc<str>>,
pub enumerators: Option<EntityId>,
pub primary_unit: Option<EntityId>,
pub secondary_unit: Option<EntityId>,
pub expression: Option<Arc<str>>,
pub access_state: Option<Arc<str>>,
pub usage_name: Option<Arc<str>>,
pub templates: Vec<PropertyTemplate>,
}Expand description
A property template: what one property should look like.
Every attribute of both template entities has a field; the ones the
entity does not declare are None (or empty). Enumeration constants are
as written in the file, without their dots.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.id: EntityIdThe entity.
name: Option<Arc<str>>Name: the property name this template governs.
description: Option<Arc<str>>Description.
kind: PropertyTemplateKindSimple or complex.
template_type: Option<Arc<str>>TemplateType: an IfcSimplePropertyTemplateTypeEnum constant such
as P_SINGLEVALUE for a simple template, an
IfcComplexPropertyTemplateTypeEnum constant (P_COMPLEX,
Q_COMPLEX) for a complex one.
This states which IfcProperty or IfcPhysicalQuantity subtype an
instance should use, so it is the link between a template and the
property families in pset.
primary_measure: Option<Arc<str>>PrimaryMeasureType, e.g. IfcLengthMeasure (simple only).
secondary_measure: Option<Arc<str>>SecondaryMeasureType, used by bounded and table values (simple
only).
enumerators: Option<EntityId>Enumerators: the IfcPropertyEnumeration an enumerated value
selects from (simple only).
primary_unit: Option<EntityId>PrimaryUnit (simple only).
secondary_unit: Option<EntityId>SecondaryUnit, the defined unit of a table value (simple only).
expression: Option<Arc<str>>Expression: a table’s correlation or a quantity’s formula (simple
only).
access_state: Option<Arc<str>>AccessState, an IfcStateEnum constant such as READONLY (simple
only).
usage_name: Option<Arc<str>>UsageName (complex only).
templates: Vec<PropertyTemplate>HasPropertyTemplates, in file order (complex only; empty when $).
Members the traversal refuses (cycle, depth, budget, absent entity, non-template) are left out; the checked readers report each one.
Implementations§
Source§impl PropertyTemplate
impl PropertyTemplate
Sourcepub fn template(&self, name: &str) -> Option<&PropertyTemplate>
pub fn template(&self, name: &str) -> Option<&PropertyTemplate>
Look up a nested template of a complex template by name.