pub struct StoichiometricCoefficient(/* private fields */);Expand description
A nonzero stoichiometric coefficient.
Implementations§
Source§impl StoichiometricCoefficient
impl StoichiometricCoefficient
Sourcepub const fn new(
value: u32,
) -> Result<StoichiometricCoefficient, StoichiometryValidationError>
pub const fn new( value: u32, ) -> Result<StoichiometricCoefficient, StoichiometryValidationError>
Creates a stoichiometric coefficient.
§Errors
Returns StoichiometryValidationError::ZeroCoefficient when value is zero.
Trait Implementations§
Source§impl Clone for StoichiometricCoefficient
impl Clone for StoichiometricCoefficient
Source§fn clone(&self) -> StoichiometricCoefficient
fn clone(&self) -> StoichiometricCoefficient
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for StoichiometricCoefficient
impl Debug for StoichiometricCoefficient
Source§impl Display for StoichiometricCoefficient
impl Display for StoichiometricCoefficient
Source§impl Hash for StoichiometricCoefficient
impl Hash for StoichiometricCoefficient
Source§impl Ord for StoichiometricCoefficient
impl Ord for StoichiometricCoefficient
Source§fn cmp(&self, other: &StoichiometricCoefficient) -> Ordering
fn cmp(&self, other: &StoichiometricCoefficient) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialOrd for StoichiometricCoefficient
impl PartialOrd for StoichiometricCoefficient
Source§impl TryFrom<u32> for StoichiometricCoefficient
impl TryFrom<u32> for StoichiometricCoefficient
Source§type Error = StoichiometryValidationError
type Error = StoichiometryValidationError
The type returned in the event of a conversion error.
Source§fn try_from(
value: u32,
) -> Result<StoichiometricCoefficient, <StoichiometricCoefficient as TryFrom<u32>>::Error>
fn try_from( value: u32, ) -> Result<StoichiometricCoefficient, <StoichiometricCoefficient as TryFrom<u32>>::Error>
Performs the conversion.
impl Copy for StoichiometricCoefficient
impl Eq for StoichiometricCoefficient
impl StructuralPartialEq for StoichiometricCoefficient
Auto Trait Implementations§
impl Freeze for StoichiometricCoefficient
impl RefUnwindSafe for StoichiometricCoefficient
impl Send for StoichiometricCoefficient
impl Sync for StoichiometricCoefficient
impl Unpin for StoichiometricCoefficient
impl UnsafeUnpin for StoichiometricCoefficient
impl UnwindSafe for StoichiometricCoefficient
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