pub struct MapEdgeRTreeObject {
pub edge_list_id: EdgeListId,
pub edge_id: EdgeId,
pub envelope: AABB<Point<f32>>,
}Expand description
rtree element for edge-oriented map matching.
Fields§
§edge_list_id: EdgeListId§edge_id: EdgeId§envelope: AABB<Point<f32>>Implementations§
Source§impl MapEdgeRTreeObject
impl MapEdgeRTreeObject
pub fn new(edge: &Edge, linestring: &LineString<f32>) -> MapEdgeRTreeObject
pub fn test_threshold( &self, point: &Point<f32>, tolerance: &Option<Length>, ) -> Result<bool, MapError>
pub fn within_distance_threshold( &self, point: &Point<f32>, tolerance: &Option<Length>, ) -> Result<(), MapError>
Trait Implementations§
Source§impl Clone for MapEdgeRTreeObject
impl Clone for MapEdgeRTreeObject
Source§fn clone(&self) -> MapEdgeRTreeObject
fn clone(&self) -> MapEdgeRTreeObject
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 PointDistance for MapEdgeRTreeObject
impl PointDistance for MapEdgeRTreeObject
Source§fn distance_2(&self, point: &Point<f32>) -> f32
fn distance_2(&self, point: &Point<f32>) -> f32
Returns the squared distance between an object and a point. Read more
Source§fn contains_point(&self, point: &<Self::Envelope as Envelope>::Point) -> bool
fn contains_point(&self, point: &<Self::Envelope as Envelope>::Point) -> bool
Returns
true if a point is contained within this object. Read moreSource§fn distance_2_if_less_or_equal(
&self,
point: &<Self::Envelope as Envelope>::Point,
max_distance_2: <<Self::Envelope as Envelope>::Point as Point>::Scalar,
) -> Option<<<Self::Envelope as Envelope>::Point as Point>::Scalar>
fn distance_2_if_less_or_equal( &self, point: &<Self::Envelope as Envelope>::Point, max_distance_2: <<Self::Envelope as Envelope>::Point as Point>::Scalar, ) -> Option<<<Self::Envelope as Envelope>::Point as Point>::Scalar>
Returns the squared distance to this object, or
None if the distance
is larger than a given maximum value. Read moreAuto Trait Implementations§
impl Freeze for MapEdgeRTreeObject
impl RefUnwindSafe for MapEdgeRTreeObject
impl Send for MapEdgeRTreeObject
impl Sync for MapEdgeRTreeObject
impl Unpin for MapEdgeRTreeObject
impl UnsafeUnpin for MapEdgeRTreeObject
impl UnwindSafe for MapEdgeRTreeObject
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more