pub struct MeasureValue {
pub measure: Option<Arc<str>>,
pub scalar: Scalar,
}Expand description
A property value together with the measure type the file declared.
Fields§
§measure: Option<Arc<str>>The declared measure, upper-cased as written, e.g. IFCLENGTHMEASURE.
None when the file wrote a bare literal. Legal, and materially
different from a stated measure: nothing can be converted or compared
dimensionally without it.
scalar: ScalarThe underlying scalar.
Implementations§
Source§impl MeasureValue
impl MeasureValue
Sourcepub fn read(value: &Value) -> Option<Self>
pub fn read(value: &Value) -> Option<Self>
Read a value, keeping its measure wrapper.
Returns None for $ (absent) and for aggregates: IfcValue is a
SELECT of single measures, so a list where a measure belongs is
malformed rather than a value this type can represent.
Trait Implementations§
Source§impl Clone for MeasureValue
impl Clone for MeasureValue
Source§impl Debug for MeasureValue
impl Debug for MeasureValue
Source§impl PartialEq for MeasureValue
impl PartialEq for MeasureValue
impl StructuralPartialEq for MeasureValue
Auto Trait Implementations§
impl Freeze for MeasureValue
impl RefUnwindSafe for MeasureValue
impl Send for MeasureValue
impl Sync for MeasureValue
impl Unpin for MeasureValue
impl UnsafeUnpin for MeasureValue
impl UnwindSafe for MeasureValue
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more