Struct rhai::FloatWrapper [−][src]
pub struct FloatWrapper<F>(_);
Expand description
A type that wraps a floating-point number and implements Hash
.
Not available under no_float
.
Implementations
impl<F: Float> FloatWrapper<F>
[src]
impl<F: Float> FloatWrapper<F>
[src]pub const MAX_NATURAL_FLOAT_FOR_DISPLAY: f32
[src]
pub const MAX_NATURAL_FLOAT_FOR_DISPLAY: f32
[src]Maximum floating-point number for natural display before switching to scientific notation.
pub const MIN_NATURAL_FLOAT_FOR_DISPLAY: f32
[src]
pub const MIN_NATURAL_FLOAT_FOR_DISPLAY: f32
[src]Minimum floating-point number for natural display before switching to scientific notation.
pub fn new(value: F) -> Self
[src]
Trait Implementations
impl<F: Float> AsMut<F> for FloatWrapper<F>
[src]
impl<F: Float> AsMut<F> for FloatWrapper<F>
[src]impl<F: Clone> Clone for FloatWrapper<F>
[src]
impl<F: Clone> Clone for FloatWrapper<F>
[src]fn clone(&self) -> FloatWrapper<F>
[src]
fn clone(&self) -> FloatWrapper<F>
[src]Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]Performs copy-assignment from source
. Read more
impl<F: Float + Debug> Debug for FloatWrapper<F>
[src]
impl<F: Float + Debug> Debug for FloatWrapper<F>
[src]impl<F: Float> Deref for FloatWrapper<F>
[src]
impl<F: Float> Deref for FloatWrapper<F>
[src]impl<F: Float> DerefMut for FloatWrapper<F>
[src]
impl<F: Float> DerefMut for FloatWrapper<F>
[src]impl<F: Float> From<F> for FloatWrapper<F>
[src]
impl<F: Float> From<F> for FloatWrapper<F>
[src]impl From<FloatWrapper<f64>> for Dynamic
[src]
impl From<FloatWrapper<f64>> for Dynamic
[src]fn from(value: FloatWrapper<FLOAT>) -> Self
[src]
fn from(value: FloatWrapper<FLOAT>) -> Self
[src]Performs the conversion.
impl<F: Float + FromStr> FromStr for FloatWrapper<F>
[src]
impl<F: Float + FromStr> FromStr for FloatWrapper<F>
[src]impl Hash for FloatWrapper<FLOAT>
[src]
impl Hash for FloatWrapper<FLOAT>
[src]impl<F: PartialEq> PartialEq<FloatWrapper<F>> for FloatWrapper<F>
[src]
impl<F: PartialEq> PartialEq<FloatWrapper<F>> for FloatWrapper<F>
[src]fn eq(&self, other: &FloatWrapper<F>) -> bool
[src]
fn eq(&self, other: &FloatWrapper<F>) -> bool
[src]This method tests for self
and other
values to be equal, and is used
by ==
. Read more
fn ne(&self, other: &FloatWrapper<F>) -> bool
[src]
fn ne(&self, other: &FloatWrapper<F>) -> bool
[src]This method tests for !=
.
impl<F: PartialOrd> PartialOrd<FloatWrapper<F>> for FloatWrapper<F>
[src]
impl<F: PartialOrd> PartialOrd<FloatWrapper<F>> for FloatWrapper<F>
[src]fn partial_cmp(&self, other: &FloatWrapper<F>) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &FloatWrapper<F>) -> Option<Ordering>
[src]This method returns an ordering between self
and other
values if one exists. Read more
#[must_use]fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]fn lt(&self, other: &Rhs) -> bool
1.0.0[src]This method tests less than (for self
and other
) and is used by the <
operator. Read more
#[must_use]fn le(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]fn le(&self, other: &Rhs) -> bool
1.0.0[src]This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
impl<F: Copy> Copy for FloatWrapper<F>
[src]
impl<F> StructuralPartialEq for FloatWrapper<F>
[src]
Auto Trait Implementations
impl<F> RefUnwindSafe for FloatWrapper<F> where
F: RefUnwindSafe,
F: RefUnwindSafe,
impl<F> Send for FloatWrapper<F> where
F: Send,
F: Send,
impl<F> Sync for FloatWrapper<F> where
F: Sync,
F: Sync,
impl<F> Unpin for FloatWrapper<F> where
F: Unpin,
F: Unpin,
impl<F> UnwindSafe for FloatWrapper<F> where
F: UnwindSafe,
F: UnwindSafe,
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> CallHasher for T where
T: Hash + ?Sized,
[src]
impl<T> CallHasher for T where
T: Hash + ?Sized,
[src]impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more