pub struct VecHistogram<A, V> { /* private fields */ }
Expand description

A Histogram that stores its values in a Vec.

See crate::ndhistogram for examples of its use.

Implementations§

source§

impl<A: Axis, V: Default + Clone> VecHistogram<A, V>

source

pub fn new(axes: A) -> Self

Factory method for VecHistogram. It is recommended to use the ndhistogram macro instead.

source§

impl<A, V> VecHistogram<A, V>

source

pub fn par_values(&self) -> impl IndexedParallelIterator<Item = &V>where V: Sync,

An immutable rayon parallel iterator over the histogram values.

This requires the “rayon” crate feature to be enabled.

source

pub fn par_values_mut(&mut self) -> impl IndexedParallelIterator<Item = &mut V>where V: Send,

A mutable rayon parallel iterator over the histogram values.

This requires the “rayon” crate feature to be enabled.

source

pub fn par_iter( &self ) -> impl IndexedParallelIterator<Item = Item<<A as Axis>::BinInterval, &V>>where A: Axis + Sync, V: Sync, <A as Axis>::BinInterval: Send,

An immutable rayon parallel iterator over bin indices, bin interval and bin values.

This requires the “rayon” crate feature to be enabled.

source

pub fn par_iter_mut( &mut self ) -> impl IndexedParallelIterator<Item = Item<<A as Axis>::BinInterval, &mut V>>where A: Axis + Sync + Send, V: Send + Sync, <A as Axis>::BinInterval: Send,

An mutable rayon parallel iterator over bin indices, bin interval and bin values.

This requires the “rayon” crate feature to be enabled.

Trait Implementations§

source§

impl<A: Axis + PartialEq + Clone, V> Add<&V> for &VecHistogram<A, V>where for<'a> &'a V: Add<Output = V>,

§

type Output = VecHistogram<A, V>

The resulting type after applying the + operator.
source§

fn add(self, rhs: &V) -> Self::Output

Performs the + operation. Read more
source§

impl<A: Axis + PartialEq + Clone, V> Add<&VecHistogram<A, V>> for &VecHistogram<A, V>where for<'a> &'a V: Add<Output = V>,

source§

fn add(self, rhs: &VecHistogram<A, V>) -> Self::Output

Combine the right-hand histogram with the left-hand histogram, returning a copy, and leaving the original histograms intact.

If the input histograms have incompatible axes, this operation will return a BinaryOperationError.

Examples
use ndhistogram::{Histogram, ndhistogram, axis::Uniform};
let mut hist1 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
let mut hist2 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
hist1.fill_with(&0.0, 2.0);
hist2.fill(&0.0);
let combined_hist = (&hist1 + &hist2).expect("Axes are compatible");
assert_eq!(combined_hist.value(&0.0).unwrap(), &3.0);
§

type Output = Result<VecHistogram<A, V>, BinaryOperationError>

The resulting type after applying the + operator.
source§

impl<A: Axis + PartialEq, V> Add<&VecHistogram<A, V>> for VecHistogram<A, V>where for<'a> V: AddAssign<&'a V>,

source§

fn add(self, rhs: &VecHistogram<A, V>) -> Self::Output

Combine the right-hand histogram with the left-hand histogram, consuming the left-hand histogram and returning a new value. As this avoids making copies of the histograms, this is the recommended method to merge histograms.

If the input histograms have incompatible axes, this operation will return a BinaryOperationError.

Examples
use ndhistogram::{Histogram, ndhistogram, axis::Uniform};
let mut hist1 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
let mut hist2 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
hist1.fill_with(&0.0, 2.0);
hist2.fill(&0.0);
let combined_hist = (hist1 + &hist2).expect("Axes are compatible");
assert_eq!(combined_hist.value(&0.0).unwrap(), &3.0);
§

type Output = Result<VecHistogram<A, V>, BinaryOperationError>

The resulting type after applying the + operator.
source§

impl<A: Axis + PartialEq, V> AddAssign<&VecHistogram<A, V>> for VecHistogram<A, V>where for<'a> V: AddAssign<&'a V>,

source§

fn add_assign(&mut self, rhs: &VecHistogram<A, V>)

Combine the right-hand histogram with the left-hand histogram, mutating the left-hand histogram.

Panics

Panics if the histograms have incompatible axes. To handle this failure mode at runtime, use the non-assign version of this operation, which returns an Result.

Examples
use ndhistogram::{Histogram, ndhistogram, axis::Uniform};
let mut hist1 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
let mut hist2 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
hist1.fill_with(&0.0, 2.0);
hist2.fill(&0.0);
hist1 += &hist2;
assert_eq!(hist1.value(&0.0).unwrap(), &3.0);
source§

impl<A: Clone, V: Clone> Clone for VecHistogram<A, V>

source§

fn clone(&self) -> VecHistogram<A, V>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<A: Debug, V: Debug> Debug for VecHistogram<A, V>

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<A: Default, V: Default> Default for VecHistogram<A, V>

source§

fn default() -> VecHistogram<A, V>

Returns the “default value” for a type. Read more
source§

impl<'de, A, V> Deserialize<'de> for VecHistogram<A, V>where A: Deserialize<'de>, V: Deserialize<'de>,

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl<A: Axis, V> Display for VecHistogram<A, V>where V: Clone + Into<f64>, A::BinInterval: Display,

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<A: Axis + PartialEq + Clone, V> Div<&V> for &VecHistogram<A, V>where for<'a> &'a V: Div<Output = V>,

§

type Output = VecHistogram<A, V>

The resulting type after applying the / operator.
source§

fn div(self, rhs: &V) -> Self::Output

Performs the / operation. Read more
source§

impl<A: Axis + PartialEq + Clone, V> Div<&VecHistogram<A, V>> for &VecHistogram<A, V>where for<'a> &'a V: Div<Output = V>,

source§

fn div(self, rhs: &VecHistogram<A, V>) -> Self::Output

Combine the right-hand histogram with the left-hand histogram, returning a copy, and leaving the original histograms intact.

If the input histograms have incompatible axes, this operation will return a BinaryOperationError.

Examples
use ndhistogram::{Histogram, ndhistogram, axis::Uniform};
let mut hist1 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
let mut hist2 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
hist1.fill_with(&0.0, 2.0);
hist2.fill(&0.0);
let combined_hist = (&hist1 / &hist2).expect("Axes are compatible");
assert_eq!(combined_hist.value(&0.0).unwrap(), &2.0);
§

type Output = Result<VecHistogram<A, V>, BinaryOperationError>

The resulting type after applying the / operator.
source§

impl<A: Axis + PartialEq, V> Div<&VecHistogram<A, V>> for VecHistogram<A, V>where for<'a> V: DivAssign<&'a V>,

source§

fn div(self, rhs: &VecHistogram<A, V>) -> Self::Output

Combine the right-hand histogram with the left-hand histogram, consuming the left-hand histogram and returning a new value. As this avoids making copies of the histograms, this is the recommended method to merge histograms.

If the input histograms have incompatible axes, this operation will return a BinaryOperationError.

Examples
use ndhistogram::{Histogram, ndhistogram, axis::Uniform};
let mut hist1 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
let mut hist2 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
hist1.fill_with(&0.0, 2.0);
hist2.fill(&0.0);
let combined_hist = (hist1 / &hist2).expect("Axes are compatible");
assert_eq!(combined_hist.value(&0.0).unwrap(), &2.0);
§

type Output = Result<VecHistogram<A, V>, BinaryOperationError>

The resulting type after applying the / operator.
source§

impl<A: Axis + PartialEq, V> DivAssign<&VecHistogram<A, V>> for VecHistogram<A, V>where for<'a> V: DivAssign<&'a V>,

source§

fn div_assign(&mut self, rhs: &VecHistogram<A, V>)

Combine the right-hand histogram with the left-hand histogram, mutating the left-hand histogram.

Panics

Panics if the histograms have incompatible axes. To handle this failure mode at runtime, use the non-assign version of this operation, which returns an Result.

Examples
use ndhistogram::{Histogram, ndhistogram, axis::Uniform};
let mut hist1 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
let mut hist2 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
hist1.fill_with(&0.0, 2.0);
hist2.fill(&0.0);
hist1 /= &hist2;
assert_eq!(hist1.value(&0.0).unwrap(), &2.0);
source§

impl<A: Hash, V: Hash> Hash for VecHistogram<A, V>

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl<A: Axis, V> Histogram<A, V> for VecHistogram<A, V>

source§

fn value(&self, coordinate: &A::Coordinate) -> Option<&V>

Read a bin value given a coordinate. Returns an Option as the given coordinate may not be mapped to a bin.
source§

fn axes(&self) -> &A

The histogram Axes that map coordinates to bin numbers.
source§

fn value_at_index(&self, index: usize) -> Option<&V>

Read a bin value given an index. Return an Option as the given index may not be valid for this histogram.
source§

fn values<'a>(&'a self) -> Box<dyn Iterator<Item = &'a V> + 'a>

Iterator over bin values.
source§

fn iter<'a>( &'a self ) -> Box<dyn Iterator<Item = Item<A::BinInterval, &'a V>> + 'a>

Iterator over bin indices, bin interval and bin values.
source§

fn value_at_index_mut(&mut self, index: usize) -> Option<&mut V>

Mutable access to a bin value at a given index.
source§

fn values_mut(&mut self) -> Box<dyn Iterator<Item = &'_ mut V> + '_>

Mutable iterator over bin values.
source§

fn iter_mut( &mut self ) -> Box<dyn Iterator<Item = Item<<A as Axis>::BinInterval, &'_ mut V>> + '_>

Mutable iterator over bin indices, bin interval and bin values.
source§

fn value_mut(&mut self, coordinate: &A::Coordinate) -> Option<&mut V>

Mutable access to a bin value at a given coordinate.
source§

fn fill_with<D>(&mut self, coordinate: &A::Coordinate, data: D)where V: FillWith<D>, Self: Sized,

Fill the histogram bin value at coordinate with some data. If the Axes do not cover that coordinate, do nothing. See FillWith.
source§

fn fill_with_weighted<D, W>( &mut self, coordinate: &A::Coordinate, data: D, weight: W )where V: FillWithWeighted<D, W>, Self: Sized,

Fill the histogram bin value at coordinate with some data. If the Axes do not cover that coordinate, do nothing. See FillWithWeighted.
source§

impl<'a, A: Axis, V> IntoIterator for &'a VecHistogram<A, V>

§

type Item = Item<<A as Axis>::BinInterval, &'a V>

The type of the elements being iterated over.
§

type IntoIter = Box<dyn Iterator<Item = Item<<A as Axis>::BinInterval, &'a V>> + 'a, Global>

Which kind of iterator are we turning this into?
source§

fn into_iter(self) -> Self::IntoIter

Creates an iterator from a value. Read more
source§

impl<'a, A: Axis, V: 'a> IntoIterator for &'a mut VecHistogram<A, V>

§

type Item = Item<<A as Axis>::BinInterval, &'a mut V>

The type of the elements being iterated over.
§

type IntoIter = Box<dyn Iterator<Item = Item<<A as Axis>::BinInterval, &'a mut V>> + 'a, Global>

Which kind of iterator are we turning this into?
source§

fn into_iter(self) -> Self::IntoIter

Creates an iterator from a value. Read more
source§

impl<A: Axis + PartialEq + Clone, V> Mul<&V> for &VecHistogram<A, V>where for<'a> &'a V: Mul<Output = V>,

§

type Output = VecHistogram<A, V>

The resulting type after applying the * operator.
source§

fn mul(self, rhs: &V) -> Self::Output

Performs the * operation. Read more
source§

impl<A: Axis + PartialEq + Clone, V> Mul<&VecHistogram<A, V>> for &VecHistogram<A, V>where for<'a> &'a V: Mul<Output = V>,

source§

fn mul(self, rhs: &VecHistogram<A, V>) -> Self::Output

Combine the right-hand histogram with the left-hand histogram, returning a copy, and leaving the original histograms intact.

If the input histograms have incompatible axes, this operation will return a BinaryOperationError.

Examples
use ndhistogram::{Histogram, ndhistogram, axis::Uniform};
let mut hist1 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
let mut hist2 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
hist1.fill_with(&0.0, 2.0);
hist2.fill(&0.0);
let combined_hist = (&hist1 * &hist2).expect("Axes are compatible");
assert_eq!(combined_hist.value(&0.0).unwrap(), &2.0);
§

type Output = Result<VecHistogram<A, V>, BinaryOperationError>

The resulting type after applying the * operator.
source§

impl<A: Axis + PartialEq, V> Mul<&VecHistogram<A, V>> for VecHistogram<A, V>where for<'a> V: MulAssign<&'a V>,

source§

fn mul(self, rhs: &VecHistogram<A, V>) -> Self::Output

Combine the right-hand histogram with the left-hand histogram, consuming the left-hand histogram and returning a new value. As this avoids making copies of the histograms, this is the recommended method to merge histograms.

If the input histograms have incompatible axes, this operation will return a BinaryOperationError.

Examples
use ndhistogram::{Histogram, ndhistogram, axis::Uniform};
let mut hist1 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
let mut hist2 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
hist1.fill_with(&0.0, 2.0);
hist2.fill(&0.0);
let combined_hist = (hist1 * &hist2).expect("Axes are compatible");
assert_eq!(combined_hist.value(&0.0).unwrap(), &2.0);
§

type Output = Result<VecHistogram<A, V>, BinaryOperationError>

The resulting type after applying the * operator.
source§

impl<A: Axis + PartialEq, V> MulAssign<&VecHistogram<A, V>> for VecHistogram<A, V>where for<'a> V: MulAssign<&'a V>,

source§

fn mul_assign(&mut self, rhs: &VecHistogram<A, V>)

Combine the right-hand histogram with the left-hand histogram, mutating the left-hand histogram.

Panics

Panics if the histograms have incompatible axes. To handle this failure mode at runtime, use the non-assign version of this operation, which returns an Result.

Examples
use ndhistogram::{Histogram, ndhistogram, axis::Uniform};
let mut hist1 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
let mut hist2 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
hist1.fill_with(&0.0, 2.0);
hist2.fill(&0.0);
hist1 *= &hist2;
assert_eq!(hist1.value(&0.0).unwrap(), &2.0);
source§

impl<A: Ord, V: Ord> Ord for VecHistogram<A, V>

source§

fn cmp(&self, other: &VecHistogram<A, V>) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 · source§

fn max(self, other: Self) -> Selfwhere Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 · source§

fn min(self, other: Self) -> Selfwhere Self: Sized,

Compares and returns the minimum of two values. Read more
1.50.0 · source§

fn clamp(self, min: Self, max: Self) -> Selfwhere Self: Sized + PartialOrd<Self>,

Restrict a value to a certain interval. Read more
source§

impl<A: PartialEq, V: PartialEq> PartialEq<VecHistogram<A, V>> for VecHistogram<A, V>

source§

fn eq(&self, other: &VecHistogram<A, V>) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl<A: PartialOrd, V: PartialOrd> PartialOrd<VecHistogram<A, V>> for VecHistogram<A, V>

source§

fn partial_cmp(&self, other: &VecHistogram<A, V>) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

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 more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl<A, V> Serialize for VecHistogram<A, V>where A: Serialize, V: Serialize,

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl<A: Axis + PartialEq + Clone, V> Sub<&V> for &VecHistogram<A, V>where for<'a> &'a V: Sub<Output = V>,

§

type Output = VecHistogram<A, V>

The resulting type after applying the - operator.
source§

fn sub(self, rhs: &V) -> Self::Output

Performs the - operation. Read more
source§

impl<A: Axis + PartialEq + Clone, V> Sub<&VecHistogram<A, V>> for &VecHistogram<A, V>where for<'a> &'a V: Sub<Output = V>,

source§

fn sub(self, rhs: &VecHistogram<A, V>) -> Self::Output

Combine the right-hand histogram with the left-hand histogram, returning a copy, and leaving the original histograms intact.

If the input histograms have incompatible axes, this operation will return a BinaryOperationError.

Examples
use ndhistogram::{Histogram, ndhistogram, axis::Uniform};
let mut hist1 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
let mut hist2 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
hist1.fill_with(&0.0, 2.0);
hist2.fill(&0.0);
let combined_hist = (&hist1 - &hist2).expect("Axes are compatible");
assert_eq!(combined_hist.value(&0.0).unwrap(), &1.0);
§

type Output = Result<VecHistogram<A, V>, BinaryOperationError>

The resulting type after applying the - operator.
source§

impl<A: Axis + PartialEq, V> Sub<&VecHistogram<A, V>> for VecHistogram<A, V>where for<'a> V: SubAssign<&'a V>,

source§

fn sub(self, rhs: &VecHistogram<A, V>) -> Self::Output

Combine the right-hand histogram with the left-hand histogram, consuming the left-hand histogram and returning a new value. As this avoids making copies of the histograms, this is the recommended method to merge histograms.

If the input histograms have incompatible axes, this operation will return a BinaryOperationError.

Examples
use ndhistogram::{Histogram, ndhistogram, axis::Uniform};
let mut hist1 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
let mut hist2 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
hist1.fill_with(&0.0, 2.0);
hist2.fill(&0.0);
let combined_hist = (hist1 - &hist2).expect("Axes are compatible");
assert_eq!(combined_hist.value(&0.0).unwrap(), &1.0);
§

type Output = Result<VecHistogram<A, V>, BinaryOperationError>

The resulting type after applying the - operator.
source§

impl<A: Axis + PartialEq, V> SubAssign<&VecHistogram<A, V>> for VecHistogram<A, V>where for<'a> V: SubAssign<&'a V>,

source§

fn sub_assign(&mut self, rhs: &VecHistogram<A, V>)

Combine the right-hand histogram with the left-hand histogram, mutating the left-hand histogram.

Panics

Panics if the histograms have incompatible axes. To handle this failure mode at runtime, use the non-assign version of this operation, which returns an Result.

Examples
use ndhistogram::{Histogram, ndhistogram, axis::Uniform};
let mut hist1 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
let mut hist2 = ndhistogram!(Uniform::<f64>::new(10, -5.0, 5.0));
hist1.fill_with(&0.0, 2.0);
hist2.fill(&0.0);
hist1 -= &hist2;
assert_eq!(hist1.value(&0.0).unwrap(), &1.0);
source§

impl<A: Eq, V: Eq> Eq for VecHistogram<A, V>

source§

impl<A, V> StructuralEq for VecHistogram<A, V>

source§

impl<A, V> StructuralPartialEq for VecHistogram<A, V>

Auto Trait Implementations§

§

impl<A, V> RefUnwindSafe for VecHistogram<A, V>where A: RefUnwindSafe, V: RefUnwindSafe,

§

impl<A, V> Send for VecHistogram<A, V>where A: Send, V: Send,

§

impl<A, V> Sync for VecHistogram<A, V>where A: Sync, V: Sync,

§

impl<A, V> Unpin for VecHistogram<A, V>where A: Unpin, V: Unpin,

§

impl<A, V> UnwindSafe for VecHistogram<A, V>where A: UnwindSafe, V: UnwindSafe,

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<D> FillWith<&D> for Dwhere D: for<'a> AddAssign<&'a D>,

source§

fn fill_with(&mut self, data: &D)

Fill this value with some data. For a simple number type means adding the weight.
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for Twhere U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

§

impl<T> Pointable for T

§

const ALIGN: usize = mem::align_of::<T>()

The alignment of pointer.
§

type Init = T

The type for initializers.
§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
source§

impl<T> ToOwned for Twhere T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T> ToString for Twhere T: Display + ?Sized,

source§

default fn to_string(&self) -> String

Converts the given value to a String. Read more
source§

impl<T, U> TryFrom<U> for Twhere U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<T> DeserializeOwned for Twhere T: for<'de> Deserialize<'de>,