pub trait OrdStoredKey: SortableBy<OrdTotalOrder<Self::OrdKeyType>> {
    type OrdKeyType: ?Sized + Ord;
}
Expand description

A helper trait implemented on potential storage key types, used to identify their default comparison type for Ord-based comparisons.

This is only really used when collections are left to select the default OrdTotalOrder total order, which essentially converts copse’s collections into those already provided by the standard library. This trait is therefore a convenience, but of relatively little value.

For example, a collection that stores String under the default total order will use str as the comparison type owing to the implementation of this trait for String.

Required Associated Types§

source

type OrdKeyType: ?Sized + Ord

The comparison type to be used by collections storing keys of Self type and using the default OrdTotalOrder total order.

Implementations on Foreign Types§

source§

impl OrdStoredKey for ()

source§

impl OrdStoredKey for bool

source§

impl OrdStoredKey for char

source§

impl OrdStoredKey for i8

source§

impl OrdStoredKey for u8

source§

impl OrdStoredKey for i16

source§

impl OrdStoredKey for u16

source§

impl OrdStoredKey for i32

source§

impl OrdStoredKey for u32

source§

impl OrdStoredKey for i64

source§

impl OrdStoredKey for u64

source§

impl OrdStoredKey for i128

source§

impl OrdStoredKey for u128

source§

impl OrdStoredKey for isize

source§

impl OrdStoredKey for usize

source§

impl OrdStoredKey for String

source§

impl OrdStoredKey for str

source§

impl OrdStoredKey for CString

source§

impl OrdStoredKey for CStr

source§

impl<B: ?Sized + Ord + Clone> OrdStoredKey for Cow<'_, B>

§

type OrdKeyType = B

source§

impl<T: ?Sized + Ord> OrdStoredKey for &T

§

type OrdKeyType = T

source§

impl<T: ?Sized + Ord> OrdStoredKey for &mut T

§

type OrdKeyType = T

source§

impl<T: ?Sized + Ord> OrdStoredKey for Rc<T>

§

type OrdKeyType = T

source§

impl<T: ?Sized + Ord> OrdStoredKey for Arc<T>

§

type OrdKeyType = T

source§

impl<T: Ord, const N: usize> OrdStoredKey for [T; N]

source§

impl<T: Ord> OrdStoredKey for [T]

source§

impl OrdStoredKey for OsString

Available on crate feature std only.
source§

impl OrdStoredKey for OsStr

Available on crate feature std only.
source§

impl OrdStoredKey for PathBuf

Available on crate feature std only.
source§

impl OrdStoredKey for Path

Available on crate feature std only.
source§

impl<T: Ord, A: Allocator> OrdStoredKey for Vec<T, A>

source§

impl<T: Ord + ?Sized, A: Allocator> OrdStoredKey for Box<T, A>

§

type OrdKeyType = T

Implementors§