pub struct Clamp<T> {
pub min: T,
pub max: T,
}Expand description
Clamp between min and max using Ord
Fields§
§min: TLowest output value
max: THighest output value
Trait Implementations§
impl<T: Copy> Copy for Clamp<T>
Auto Trait Implementations§
impl<T> Freeze for Clamp<T>where
T: Freeze,
impl<T> RefUnwindSafe for Clamp<T>where
T: RefUnwindSafe,
impl<T> Send for Clamp<T>where
T: Send,
impl<T> Sync for Clamp<T>where
T: Sync,
impl<T> Unpin for Clamp<T>where
T: Unpin,
impl<T> UnwindSafe for Clamp<T>where
T: 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