pub struct ConstructionResource<'m, 's> { /* private fields */ }Expand description
Borrowed projection of a concrete IfcConstructionResource occurrence.
Implementations§
Source§impl<'m, 's> ConstructionResource<'m, 's>
impl<'m, 's> ConstructionResource<'m, 's>
Sourcepub fn kind(&self) -> ResourceKind
pub fn kind(&self) -> ResourceKind
Which concrete IfcConstructionResource subtype this occurrence is.
Sourcepub fn name(&self) -> ResourceResult<Option<&'m str>>
pub fn name(&self) -> ResourceResult<Option<&'m str>>
The Name attribute, when authored.
Sourcepub fn identification(&self) -> ResourceResult<Option<&'m str>>
pub fn identification(&self) -> ResourceResult<Option<&'m str>>
The Identification attribute, when authored.
Under IFC2X3 this reads ResourceIdentifier, the IfcIdentifier
IFC2X3 declares in the same position.
Sourcepub fn long_description(&self) -> ResourceResult<Option<&'m str>>
pub fn long_description(&self) -> ResourceResult<Option<&'m str>>
The LongDescription attribute, when authored; IFC2X3 declares none
(ResourceError::NotInSchema).
Sourcepub fn predefined_type(&self) -> ResourceResult<Option<&'m str>>
pub fn predefined_type(&self) -> ResourceResult<Option<&'m str>>
The PredefinedType enumeration, when authored; no IFC2X3 resource
declares one (ResourceError::NotInSchema).
A USERDEFINED value requires ObjectType to be set; that
constraint is enforced here rather than left to the caller.
Sourcepub fn usage(&self) -> ResourceResult<Option<ResourceTime<'m, 's>>>
pub fn usage(&self) -> ResourceResult<Option<ResourceTime<'m, 's>>>
The Usage attribute: authored IfcResourceTime, when present;
IFC2X3 declares neither (ResourceError::NotInSchema).
Sourcepub fn base_costs(&self) -> ResourceResult<Vec<EntityId>>
pub fn base_costs(&self) -> ResourceResult<Vec<EntityId>>
The BaseCosts attribute: applied-value references, when authored;
IFC2X3 declares none (ResourceError::NotInSchema).
Sourcepub fn base_quantity(&self) -> ResourceResult<Option<EntityId>>
pub fn base_quantity(&self) -> ResourceResult<Option<EntityId>>
The BaseQuantity attribute: the physical-quantity reference, when
authored.
IFC2X3 declares BaseQuantity as an IfcMeasureWithUnit, not a
physical quantity, so this refuses with
ResourceError::NotInSchema there; read it with
ConstructionResource::base_quantity_measure.
Sourcepub fn base_quantity_measure(&self) -> ResourceResult<Option<EntityId>>
pub fn base_quantity_measure(&self) -> ResourceResult<Option<EntityId>>
IFC2X3 IfcConstructionResource.BaseQuantity: the
IfcMeasureWithUnit reference, when authored. Project it with
ResourceView::measure_with_unit.
IFC4 and IFC4X3 declare BaseQuantity as an IfcPhysicalQuantity,
read by ConstructionResource::base_quantity; this refuses there
with ResourceError::NotInSchema.
Sourcepub fn resource_group(&self) -> ResourceResult<Option<&'m str>>
pub fn resource_group(&self) -> ResourceResult<Option<&'m str>>
IFC2X3 IfcConstructionResource.ResourceGroup (IfcLabel), when
authored. ResourceError::NotInSchema under IFC4 and IFC4X3.
Sourcepub fn resource_consumption(&self) -> ResourceResult<Option<&'m str>>
pub fn resource_consumption(&self) -> ResourceResult<Option<&'m str>>
IFC2X3 IfcConstructionResource.ResourceConsumption
(IfcResourceConsumptionEnum), when authored, checked against the
release’s declared members. ResourceError::NotInSchema under
IFC4 and IFC4X3.
Sourcepub fn skill_set(&self) -> ResourceResult<Option<&'m str>>
pub fn skill_set(&self) -> ResourceResult<Option<&'m str>>
IFC2X3 IfcLaborResource.SkillSet (IfcText), when authored.
ResourceError::NotInSchema on any other kind and under IFC4 and
IFC4X3.
Sourcepub fn suppliers(&self) -> ResourceResult<Vec<EntityId>>
pub fn suppliers(&self) -> ResourceResult<Vec<EntityId>>
IFC2X3 IfcConstructionMaterialResource.Suppliers
(SET [1:?] OF IfcActorSelect): person, organization or
person-and-organization references, empty when unset.
ResourceError::NotInSchema on any other kind and under IFC4 and
IFC4X3.
Sourcepub fn usage_ratio(&self) -> ResourceResult<Option<f64>>
pub fn usage_ratio(&self) -> ResourceResult<Option<f64>>
IFC2X3 IfcConstructionMaterialResource.UsageRatio
(IfcRatioMeasure), when authored; a non-finite value is refused.
ResourceError::NotInSchema on any other kind and under IFC4 and
IFC4X3.
Sourcepub fn sub_contractor(&self) -> ResourceResult<Option<EntityId>>
pub fn sub_contractor(&self) -> ResourceResult<Option<EntityId>>
IFC2X3 IfcSubContractResource.SubContractor (IfcActorSelect),
when authored. ResourceError::NotInSchema on any other kind and
under IFC4 and IFC4X3.
Sourcepub fn job_description(&self) -> ResourceResult<Option<&'m str>>
pub fn job_description(&self) -> ResourceResult<Option<&'m str>>
IFC2X3 IfcSubContractResource.JobDescription (IfcText), when
authored. ResourceError::NotInSchema on any other kind and under
IFC4 and IFC4X3.
Trait Implementations§
Source§impl<'m, 's> Clone for ConstructionResource<'m, 's>
impl<'m, 's> Clone for ConstructionResource<'m, 's>
Source§fn clone(&self) -> ConstructionResource<'m, 's>
fn clone(&self) -> ConstructionResource<'m, 's>
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more