pub trait AssertIsSorted {
// Required methods
fn is_sorted_ascending(self) -> Self;
fn is_sorted_descending(self) -> Self;
}
Expand description
Assert the order of the values within a collection.
These assertions are applicable to ordered collections only.
Required Methods§
Sourcefn is_sorted_ascending(self) -> Self
fn is_sorted_ascending(self) -> Self
Verifies that the actual collection is sorted in ascending order.
Sourcefn is_sorted_descending(self) -> Self
fn is_sorted_descending(self) -> Self
Verifies that the actual collection is sorted in descending order.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.