Struct cansat_core::quantity::Temperature
source · pub struct Temperature(_);
Implementations§
source§impl Temperature
impl Temperature
pub const fn from_celsius(value: f32) -> Self
pub fn from_kelvins(value: f32) -> Self
pub const fn as_celsius(&self) -> f32
pub fn as_kelvins(&self) -> f32
Trait Implementations§
source§impl Add<Temperature> for Temperature
impl Add<Temperature> for Temperature
§type Output = Temperature
type Output = Temperature
The resulting type after applying the
+
operator.source§fn add(self, rhs: Temperature) -> Temperature
fn add(self, rhs: Temperature) -> Temperature
Performs the
+
operation. Read moresource§impl Clone for Temperature
impl Clone for Temperature
source§fn clone(&self) -> Temperature
fn clone(&self) -> Temperature
Returns a copy 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<__RhsT> Div<__RhsT> for Temperaturewhere
f32: Div<__RhsT, Output = f32>,
impl<__RhsT> Div<__RhsT> for Temperaturewhere f32: Div<__RhsT, Output = f32>,
§type Output = Temperature
type Output = Temperature
The resulting type after applying the
/
operator.source§fn div(self, rhs: __RhsT) -> Temperature
fn div(self, rhs: __RhsT) -> Temperature
Performs the
/
operation. Read moresource§impl<__RhsT> Mul<__RhsT> for Temperaturewhere
f32: Mul<__RhsT, Output = f32>,
impl<__RhsT> Mul<__RhsT> for Temperaturewhere f32: Mul<__RhsT, Output = f32>,
§type Output = Temperature
type Output = Temperature
The resulting type after applying the
*
operator.source§fn mul(self, rhs: __RhsT) -> Temperature
fn mul(self, rhs: __RhsT) -> Temperature
Performs the
*
operation. Read moresource§impl PartialEq<Temperature> for Temperature
impl PartialEq<Temperature> for Temperature
source§fn eq(&self, other: &Temperature) -> bool
fn eq(&self, other: &Temperature) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd<Temperature> for Temperature
impl PartialOrd<Temperature> for Temperature
source§fn partial_cmp(&self, other: &Temperature) -> Option<Ordering>
fn partial_cmp(&self, other: &Temperature) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl Sub<Temperature> for Temperature
impl Sub<Temperature> for Temperature
§type Output = Temperature
type Output = Temperature
The resulting type after applying the
-
operator.source§fn sub(self, rhs: Temperature) -> Temperature
fn sub(self, rhs: Temperature) -> Temperature
Performs the
-
operation. Read moreimpl Copy for Temperature
impl StructuralPartialEq for Temperature
Auto Trait Implementations§
impl RefUnwindSafe for Temperature
impl Send for Temperature
impl Sync for Temperature
impl Unpin for Temperature
impl UnwindSafe for Temperature
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