pub struct ConstantBound<C: Constant> { /* private fields */ }Expand description
A bound for a generic Constant.
Trait Implementations§
Source§impl<C: Constant> Bound for ConstantBound<C>
impl<C: Constant> Bound for ConstantBound<C>
Source§fn max_constant() -> Option<Self::Constant>
fn max_constant() -> Option<Self::Constant>
The maximal value of the bounding constant if it exists.
Source§fn min_constant() -> Option<Self::Constant>
fn min_constant() -> Option<Self::Constant>
The minimal value of the bounding constant if it exists.
Source§fn is_unbounded(&self) -> bool
fn is_unbounded(&self) -> bool
Returns whether the bound is the unbounded bound.
Source§fn constant(&self) -> Option<Self::Constant>
fn constant(&self) -> Option<Self::Constant>
Retrieves the constant associated with the bound. Read more
Source§fn add(&self, other: &Self) -> Option<Self>
fn add(&self, other: &Self) -> Option<Self>
Constructs a new bound by adding the constants of both bounds. Read more
Source§fn is_tighter_than(&self, other: &Self) -> bool
fn is_tighter_than(&self, other: &Self) -> bool
Returns whether
self is a tighter bound than other.Source§impl<C: Clone + Constant> Clone for ConstantBound<C>
impl<C: Clone + Constant> Clone for ConstantBound<C>
Source§fn clone(&self) -> ConstantBound<C>
fn clone(&self) -> ConstantBound<C>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl<C: Eq + Constant> Eq for ConstantBound<C>
impl<C: Constant> StructuralPartialEq for ConstantBound<C>
Auto Trait Implementations§
impl<C> Freeze for ConstantBound<C>where
C: Freeze,
impl<C> RefUnwindSafe for ConstantBound<C>where
C: RefUnwindSafe,
impl<C> Send for ConstantBound<C>where
C: Send,
impl<C> Sync for ConstantBound<C>where
C: Sync,
impl<C> Unpin for ConstantBound<C>where
C: Unpin,
impl<C> UnwindSafe for ConstantBound<C>where
C: UnwindSafe,
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