Struct uncertain::BoxedUncertain [−][src]
An opaque uncertain value.
This is useful when you need to conditionally return different uncertain values.
See into_boxed
.
Trait Implementations
impl<T> Uncertain for BoxedUncertain<T>
[src]
type Value = T
The type of the contained value.
fn sample(&self, rng: &mut Pcg32, epoch: usize) -> Self::Value
[src]
fn pr(&self, probability: f32) -> bool where
Self::Value: Into<bool>,
[src]
Self::Value: Into<bool>,
fn expect(
&self,
precision: Self::Value
) -> Result<Self::Value, ConvergenceError<Self::Value>> where
Self::Value: Float,
[src]
&self,
precision: Self::Value
) -> Result<Self::Value, ConvergenceError<Self::Value>> where
Self::Value: Float,
fn into_boxed(self) -> BoxedUncertain<Self::Value> where
Self: 'static + Sized + Send,
[src]
Self: 'static + Sized + Send,
fn into_ref(self) -> RefUncertain<Self> where
Self: Sized,
Self::Value: Clone,
[src]
Self: Sized,
Self::Value: Clone,
fn map<O, F>(self, func: F) -> Map<Self, F> where
Self: Sized,
F: Fn(Self::Value) -> O,
[src]
Self: Sized,
F: Fn(Self::Value) -> O,
fn flat_map<O, F>(self, func: F) -> FlatMap<Self, F> where
Self: Sized,
O: Uncertain,
F: Fn(Self::Value) -> O,
[src]
Self: Sized,
O: Uncertain,
F: Fn(Self::Value) -> O,
fn join<O, U, F>(self, other: U, func: F) -> Join<Self, U, F> where
Self: Sized,
U: Uncertain,
F: Fn(Self::Value, U::Value) -> O,
[src]
Self: Sized,
U: Uncertain,
F: Fn(Self::Value, U::Value) -> O,
fn not(self) -> Not<Self> where
Self: Sized,
Self::Value: Into<bool>,
[src]
Self: Sized,
Self::Value: Into<bool>,
fn and<U>(self, other: U) -> And<Self, U> where
Self: Sized,
Self::Value: Into<bool>,
U: Uncertain,
U::Value: Into<bool>,
[src]
Self: Sized,
Self::Value: Into<bool>,
U: Uncertain,
U::Value: Into<bool>,
fn or<U>(self, other: U) -> Or<Self, U> where
Self: Sized,
Self::Value: Into<bool>,
U: Uncertain,
U::Value: Into<bool>,
[src]
Self: Sized,
Self::Value: Into<bool>,
U: Uncertain,
U::Value: Into<bool>,
fn add<U>(self, other: U) -> Sum<Self, U> where
Self: Sized,
U: Uncertain,
Self::Value: Add<U::Value>,
[src]
Self: Sized,
U: Uncertain,
Self::Value: Add<U::Value>,
fn sub<U>(self, other: U) -> Difference<Self, U> where
Self: Sized,
U: Uncertain,
Self::Value: Sub<U::Value>,
[src]
Self: Sized,
U: Uncertain,
Self::Value: Sub<U::Value>,
fn mul<U>(self, other: U) -> Product<Self, U> where
Self: Sized,
U: Uncertain,
Self::Value: Mul<U::Value>,
[src]
Self: Sized,
U: Uncertain,
Self::Value: Mul<U::Value>,
fn div<U>(self, other: U) -> Ratio<Self, U> where
Self: Sized,
U: Uncertain,
Self::Value: Div<U::Value>,
[src]
Self: Sized,
U: Uncertain,
Self::Value: Div<U::Value>,
Auto Trait Implementations
impl<T> !RefUnwindSafe for BoxedUncertain<T>
impl<T> Send for BoxedUncertain<T>
impl<T> !Sync for BoxedUncertain<T>
impl<T> Unpin for BoxedUncertain<T>
impl<T> !UnwindSafe for BoxedUncertain<T>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,