pub struct MultiPoint<'a, T: Coord> { /* private fields */ }
Expand description
Computer-friendly MultiPoint
Implementations§
Source§impl<'a, T: Coord> MultiPoint<'a, T>
impl<'a, T: Coord> MultiPoint<'a, T>
pub fn from_raw(coords: Cow<'a, [T]>) -> Self
pub fn raw_coords(&self) -> &[T]
Sourcepub fn iter_range(&self, range: Range<usize>) -> Iter<'_, T>
pub fn iter_range(&self, range: Range<usize>) -> Iter<'_, T>
Returns iterator over the points in the given range.
Sourcepub fn transform<T2: Coord>(&self, f: impl Fn(&T) -> T2) -> MultiPoint<'_, T2>
pub fn transform<T2: Coord>(&self, f: impl Fn(&T) -> T2) -> MultiPoint<'_, T2>
Create a new MultiPoint by applying the given transformation to all coordinates.
Sourcepub fn transform_inplace(&mut self, f: impl FnMut(&T) -> T)
pub fn transform_inplace(&mut self, f: impl FnMut(&T) -> T)
Applies the given transformation to all coordinates in the MultiPoint.
Trait Implementations§
Source§impl<'a, T: Clone + Coord> Clone for MultiPoint<'a, T>
impl<'a, T: Clone + Coord> Clone for MultiPoint<'a, T>
Source§fn clone(&self) -> MultiPoint<'a, T>
fn clone(&self) -> MultiPoint<'a, T>
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 moreSource§impl<'a, T: Default + Coord> Default for MultiPoint<'a, T>
impl<'a, T: Default + Coord> Default for MultiPoint<'a, T>
Source§fn default() -> MultiPoint<'a, T>
fn default() -> MultiPoint<'a, T>
Returns the “default value” for a type. Read more
Source§impl<'a, T: Coord> IntoIterator for &'a MultiPoint<'_, T>
impl<'a, T: Coord> IntoIterator for &'a MultiPoint<'_, T>
impl<'a, T: Coord> StructuralPartialEq for MultiPoint<'a, T>
Auto Trait Implementations§
impl<'a, T> Freeze for MultiPoint<'a, T>
impl<'a, T> RefUnwindSafe for MultiPoint<'a, T>where
T: RefUnwindSafe,
impl<'a, T> Send for MultiPoint<'a, T>
impl<'a, T> Sync for MultiPoint<'a, T>where
T: Sync,
impl<'a, T> Unpin for MultiPoint<'a, T>where
T: Unpin,
impl<'a, T> UnwindSafe for MultiPoint<'a, T>where
T: RefUnwindSafe + 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