pub struct BoundsRefinement<T: Clone + Debug + Default + PartialEq> {
pub origin: Option<Point<T>>,
pub size: Option<Size<T>>,
}Expand description
A refinable version of [#ident], see that documentation for details.
Fields§
§origin: Option<Point<T>>§size: Option<Size<T>>Implementations§
Trait Implementations§
Source§impl<T: Clone + Debug + Default + PartialEq> From<BoundsRefinement<T>> for Bounds<T>
impl<T: Clone + Debug + Default + PartialEq> From<BoundsRefinement<T>> for Bounds<T>
Source§fn from(value: BoundsRefinement<T>) -> Self
fn from(value: BoundsRefinement<T>) -> Self
Converts to this type from the input type.
Source§impl<T: Clone + Debug + Default + PartialEq> Refineable for BoundsRefinement<T>
impl<T: Clone + Debug + Default + PartialEq> Refineable for BoundsRefinement<T>
type Refinement = BoundsRefinement<T>
Source§fn refine(&mut self, refinement: &Self::Refinement)
fn refine(&mut self, refinement: &Self::Refinement)
Applies the given refinement to this instance, modifying it in place. Read more
Source§fn refined(self, refinement: Self::Refinement) -> Self
fn refined(self, refinement: Self::Refinement) -> Self
Returns a new instance with the refinement applied, equivalent to cloning
self and calling
refine on it.Source§fn is_superset_of(&self, refinement: &Self::Refinement) -> bool
fn is_superset_of(&self, refinement: &Self::Refinement) -> bool
Returns
true if this instance would contain all values from the refinement. Read moreSource§fn subtract(&self, refinement: &Self::Refinement) -> Self::Refinement
fn subtract(&self, refinement: &Self::Refinement) -> Self::Refinement
Returns a refinement that represents the difference between this instance and the given
refinement. Read more
Auto Trait Implementations§
impl<T> Freeze for BoundsRefinement<T>
impl<T> RefUnwindSafe for BoundsRefinement<T>
impl<T> Send for BoundsRefinement<T>
impl<T> Sync for BoundsRefinement<T>
impl<T> Unpin for BoundsRefinement<T>
impl<T> UnsafeUnpin for BoundsRefinement<T>
impl<T> UnwindSafe for BoundsRefinement<T>
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