pub struct Unit { /* private fields */ }Expand description
ISO 23387 UnitType, with all required scalar/reference fields present.
Implementations§
Source§impl Unit
impl Unit
pub const fn new( concept: Concept, dimension_ref: Reference, scale: Scale, base: Base, coefficient: Rational, offset: Rational, ) -> Self
pub const fn concept(&self) -> &Concept
pub fn symbols(&self) -> &[MultiLanguageText]
pub fn add_symbol(&mut self, value: MultiLanguageText)
pub const fn dimension_ref(&self) -> &Reference
pub const fn scale(&self) -> &Scale
pub const fn base(&self) -> &Base
pub const fn coefficient(&self) -> &Rational
pub const fn offset(&self) -> &Rational
Trait Implementations§
impl Eq for Unit
impl StructuralPartialEq for Unit
Auto Trait Implementations§
impl Freeze for Unit
impl RefUnwindSafe for Unit
impl Send for Unit
impl Sync for Unit
impl Unpin for Unit
impl UnwindSafe for Unit
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