Class ElementProjection<Element>
java.lang.Object
com.here.platform.location.core.geospatial.ElementProjection<Element>
- Type Parameters:
Element- The type of the element with a geometry
- All Implemented Interfaces:
FractionOn<Element>,Serializable,scala.Equals,scala.Product
public class ElementProjection<Element>
extends Object
implements FractionOn<Element>, scala.Product, Serializable
Encapsulates a geometry, the nearest point on the geometry to some input point, and the distance between the two.
See also ProximitySearch.search(GC, double, com.here.platform.location.core.geospatial.GeoCoordinateOperations<GC>).
param: element The element with a geometry
param: nearest The nearest coordinates on element's geometry to the input point
param: distanceInMeters The distance between the input point and the nearest point on element's geometry
param: fraction The fraction along the length of element from its beginning to nearest
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionElementProjection(Element element, GeoCoordinate nearest, double distanceInMeters, double fraction) -
Method Summary
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface scala.Equals
canEqual, equalsMethods inherited from interface scala.Product
productArity, productElement, productElementName, productElementNames, productIterator, productPrefix
-
Constructor Details
-
ElementProjection
public ElementProjection(Element element, GeoCoordinate nearest, double distanceInMeters, double fraction)
-
-
Method Details
-
element
- Specified by:
elementin interfaceFractionOn<Element>
-
nearest
-
distanceInMeters
public double distanceInMeters() -
fraction
public double fraction()Description copied from interface:FractionOnThe fraction specifies how far along the length ofelementthe point is located. It has a value between 0.0 (the point is at the start ofelement) and 1.0 (the point is at the end ofelement).- Specified by:
fractionin interfaceFractionOn<Element>
-
getDistanceInMeters
public double getDistanceInMeters() -
getElement
-
getFraction
public double getFraction() -
getNearest
-