pub struct SideDistances { /* private fields */ }Expand description
The candidates beside an object’s sides, with the rectangle they were measured from.
Implementations§
Source§impl SideDistances
impl SideDistances
Sourcepub fn try_new(
request: SideDistanceRequest,
rectangle: PlanRectangle,
distances: Vec<SideDistance>,
evidence: Evidence,
) -> Result<Self, PlanSpanError>
pub fn try_new( request: SideDistanceRequest, rectangle: PlanRectangle, distances: Vec<SideDistance>, evidence: Evidence, ) -> Result<Self, PlanSpanError>
The answer to request from rectangle.
The rectangle must be the request object’s, with a unique orientation; each candidate appears at most once per side and only if requested; the evidence is exact only when the rectangle and every distance are, and every candidate is surely present.
Sourcepub fn request(&self) -> &SideDistanceRequest
pub fn request(&self) -> &SideDistanceRequest
The request answered.
Sourcepub fn rectangle(&self) -> &PlanRectangle
pub fn rectangle(&self) -> &PlanRectangle
The object’s least-area rectangle.
Sourcepub fn distances(&self) -> &[SideDistance]
pub fn distances(&self) -> &[SideDistance]
Every listed candidate, by side and then candidate.
Sourcepub fn beside(&self, side: RectangleSide) -> impl Iterator<Item = &SideDistance>
pub fn beside(&self, side: RectangleSide) -> impl Iterator<Item = &SideDistance>
The candidates listed beside side.
Trait Implementations§
Source§impl Clone for SideDistances
impl Clone for SideDistances
Source§impl Debug for SideDistances
impl Debug for SideDistances
Source§impl PartialEq for SideDistances
impl PartialEq for SideDistances
impl StructuralPartialEq for SideDistances
Auto Trait Implementations§
impl Freeze for SideDistances
impl RefUnwindSafe for SideDistances
impl Send for SideDistances
impl Sync for SideDistances
impl Unpin for SideDistances
impl UnsafeUnpin for SideDistances
impl UnwindSafe for SideDistances
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