Trait sp_arithmetic::ThresholdOrd
source · pub trait ThresholdOrd<T> {
// Required method
fn tcmp(&self, other: &T, threshold: T) -> Ordering;
}Expand description
Trait for comparing two numbers with an threshold.
Returns:
Ordering::Greaterifselfis greater thanother + threshold.Ordering::Lessifselfis less thanother - threshold.Ordering::Equalotherwise.