Skip to main content

NonEmptyBoxedSlice

Type Alias NonEmptyBoxedSlice 

Source
pub type NonEmptyBoxedSlice<T> = Box<NonEmptySlice<T>>;
Expand description

Represents non-empty boxed slices, Box<NonEmptySlice<T>>.

Aliased Type§

pub struct NonEmptyBoxedSlice<T>(/* private fields */);

Trait Implementations§

Source§

impl<T: Clone> Clone for NonEmptyBoxedSlice<T>

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
Source§

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

Performs copy-assignment from source. Read more
Source§

impl<'de, T: Deserialize<'de>> Deserialize<'de> for NonEmptyBoxedSlice<T>

Available on crate feature serde and (crate features std or alloc) only.
Source§

fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>

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

impl<T: Clone> From<&NonEmptySlice<T>> for NonEmptyBoxedSlice<T>

Source§

fn from(non_empty: &NonEmptySlice<T>) -> Self

Converts to this type from the input type.
Source§

impl<T: Clone> From<&mut NonEmptySlice<T>> for NonEmptyBoxedSlice<T>

Source§

fn from(non_empty: &mut NonEmptySlice<T>) -> Self

Converts to this type from the input type.
Source§

impl<T: Clone> From<Cow<'_, NonEmptySlice<T>>> for NonEmptyBoxedSlice<T>

Source§

fn from(non_empty: NonEmptyCowSlice<'_, T>) -> Self

Converts to this type from the input type.
Source§

impl<T> From<NonEmptyVec<T>> for NonEmptyBoxedSlice<T>

Source§

fn from(non_empty: NonEmptyVec<T>) -> Self

Converts to this type from the input type.
Source§

impl<T> FromNonEmptyIterator<T> for NonEmptyBoxedSlice<T>

Source§

fn from_non_empty_iter<I: IntoNonEmptyIterator<Item = T>>(iterable: I) -> Self

Creates Self from the provided non-empty iterator.
Source§

impl<T> IntoIterator for NonEmptyBoxedSlice<T>

Source§

type Item = T

The type of the elements being iterated over.
Source§

type IntoIter = IntoIter<T>

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<T> IntoNonEmptyIterator for NonEmptyBoxedSlice<T>

Source§

type IntoNonEmptyIter = NonEmptyAdapter<IntoIter<T>>

What kind of NonEmptyIterator are we turning this into?
Source§

fn into_non_empty_iter(self) -> Self::IntoNonEmptyIter

Converts self into NonEmptyIterator.
Source§

impl<T: IntoOwned> IntoOwned for NonEmptyBoxedSlice<T>

Available on crate feature ownership and (crate features std or alloc) only.
Source§

type Owned = Box<NonEmptySlice<<T as IntoOwned>::Owned>>

The owned type produced by into_owned. Read more
Source§

fn into_owned(self) -> Self::Owned

Consumes Self and converts it into the associated Owned type.
Source§

impl<T: PartialEq<U>, U> PartialEq<[U]> for NonEmptyBoxedSlice<T>

Available on crate features std or alloc only.
Source§

fn eq(&self, other: &[U]) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

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

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl<T: PartialEq<U>, U> PartialEq<Box<[U]>> for NonEmptyBoxedSlice<T>

Available on crate features std or alloc only.
Source§

fn eq(&self, other: &Box<[U]>) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

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

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl<T: PartialEq<U>, U: Clone> PartialEq<Cow<'_, [U]>> for NonEmptyBoxedSlice<T>

Available on crate features std or alloc only.
Source§

fn eq(&self, other: &Cow<'_, [U]>) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

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

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl<T: PartialEq<U>, U: Clone> PartialEq<Cow<'_, NonEmptySlice<U>>> for NonEmptyBoxedSlice<T>

Available on crate features std or alloc only.
Source§

fn eq(&self, other: &NonEmptyCowSlice<'_, U>) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

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

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl<T: PartialEq<U>, U> PartialEq<NonEmptySlice<U>> for NonEmptyBoxedSlice<T>

Available on crate features std or alloc only.
Source§

fn eq(&self, other: &NonEmptySlice<U>) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

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

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl<T: PartialEq<U>, U> PartialEq<NonEmptyVec<U>> for NonEmptyBoxedSlice<T>

Available on crate features std or alloc only.
Source§

fn eq(&self, other: &NonEmptyVec<U>) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

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

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl<T: PartialEq<U>, U> PartialEq<Vec<U>> for NonEmptyBoxedSlice<T>

Available on crate features std or alloc only.
Source§

fn eq(&self, other: &Vec<U>) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

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

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl<T: PartialOrd> PartialOrd<[T]> for NonEmptyBoxedSlice<T>

Available on crate features std or alloc only.
Source§

fn partial_cmp(&self, other: &[T]) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 (const: unstable) · Source§

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

Tests less than (for self and other) and is used by the < operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests greater than or equal to (for self and other) and is used by the >= operator. Read more
Source§

impl<T: PartialOrd> PartialOrd<Box<[T]>> for NonEmptyBoxedSlice<T>

Available on crate features std or alloc only.
Source§

fn partial_cmp(&self, other: &Box<[T]>) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 (const: unstable) · Source§

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

Tests less than (for self and other) and is used by the < operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests greater than or equal to (for self and other) and is used by the >= operator. Read more
Source§

impl<T: PartialOrd + Clone> PartialOrd<Cow<'_, [T]>> for NonEmptyBoxedSlice<T>

Available on crate features std or alloc only.
Source§

fn partial_cmp(&self, other: &Cow<'_, [T]>) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 (const: unstable) · Source§

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

Tests less than (for self and other) and is used by the < operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests greater than or equal to (for self and other) and is used by the >= operator. Read more
Source§

impl<T: PartialOrd + Clone> PartialOrd<Cow<'_, NonEmptySlice<T>>> for NonEmptyBoxedSlice<T>

Available on crate features std or alloc only.
Source§

fn partial_cmp(&self, other: &NonEmptyCowSlice<'_, T>) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 (const: unstable) · Source§

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

Tests less than (for self and other) and is used by the < operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests greater than or equal to (for self and other) and is used by the >= operator. Read more
Source§

impl<T: PartialOrd> PartialOrd<NonEmptySlice<T>> for NonEmptyBoxedSlice<T>

Available on crate features std or alloc only.
Source§

fn partial_cmp(&self, other: &NonEmptySlice<T>) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 (const: unstable) · Source§

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

Tests less than (for self and other) and is used by the < operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests greater than or equal to (for self and other) and is used by the >= operator. Read more
Source§

impl<T: PartialOrd> PartialOrd<NonEmptyVec<T>> for NonEmptyBoxedSlice<T>

Available on crate features std or alloc only.
Source§

fn partial_cmp(&self, other: &NonEmptyVec<T>) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 (const: unstable) · Source§

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

Tests less than (for self and other) and is used by the < operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests greater than or equal to (for self and other) and is used by the >= operator. Read more
Source§

impl<T: PartialOrd> PartialOrd<Vec<T>> for NonEmptyBoxedSlice<T>

Available on crate features std or alloc only.
Source§

fn partial_cmp(&self, other: &Vec<T>) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 (const: unstable) · Source§

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

Tests less than (for self and other) and is used by the < operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests greater than or equal to (for self and other) and is used by the >= operator. Read more
Source§

impl<T: Clone> TryFrom<&[T]> for NonEmptyBoxedSlice<T>

Source§

type Error = EmptySlice

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

fn try_from(slice: &[T]) -> Result<Self, Self::Error>

Performs the conversion.
Source§

impl<T: Clone> TryFrom<&mut [T]> for NonEmptyBoxedSlice<T>

Source§

type Error = EmptySlice

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

fn try_from(slice: &mut [T]) -> Result<Self, Self::Error>

Performs the conversion.
Source§

impl<T> TryFrom<Box<[T]>> for NonEmptyBoxedSlice<T>

Source§

type Error = EmptyBoxedSlice<T>

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

fn try_from(boxed: Box<[T]>) -> Result<Self, Self::Error>

Performs the conversion.
Source§

impl<T> TryFrom<Vec<T>> for NonEmptyBoxedSlice<T>

Source§

type Error = EmptyVec<T>

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

fn try_from(vec: Vec<T>) -> Result<Self, Self::Error>

Performs the conversion.