pub enum Rel {
Greater(Option<DecCnt>),
Equal,
Lesser(Option<DecCnt>),
}Expand description
Relation enumeration.
use big_num_math::{rel, PlacesRow, Rel, DecCnt};
let num_1 = PlacesRow::new_from_usize(100);
let num_2 = PlacesRow::new_from_usize(101);
let num_3 = PlacesRow::new_from_usize(1);
assert_eq!(Rel::Lesser(None), rel(&num_1, &num_2));
let cnt_1_cnt_2_dif: DecCnt = (1,3,2);
assert_eq!(Rel::Lesser(Some(cnt_1_cnt_2_dif)), rel(&num_3, &num_1));Variants§
Greater(Option<DecCnt>)
Greater than comparand. Holds information about decimal difference, if there is some.
Equal
Equal to comparand.
Lesser(Option<DecCnt>)
Lesser than comparand. Holds information about decimal difference, if there is some.
Trait Implementations§
impl StructuralPartialEq for Rel
Auto Trait Implementations§
impl Freeze for Rel
impl RefUnwindSafe for Rel
impl Send for Rel
impl Sync for Rel
impl Unpin for Rel
impl UnwindSafe for Rel
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more