Package org.apache.lucene.spatial3d.geom
Class GeoStandardPath.BaseSegmentEndpoint
java.lang.Object
org.apache.lucene.spatial3d.geom.GeoStandardPath.BaseSegmentEndpoint
- All Implemented Interfaces:
GeoStandardPath.SegmentEndpoint
- Direct Known Subclasses:
GeoStandardPath.CircleSegmentEndpoint,GeoStandardPath.CutoffDualCircleSegmentEndpoint
- Enclosing class:
- GeoStandardPath
private static class GeoStandardPath.BaseSegmentEndpoint
extends Object
implements GeoStandardPath.SegmentEndpoint
Base implementation of SegmentEndpoint
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static final Membership[]Null membershipprotected final GeoPointThe center point of the endpoint -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanvoidgetBounds(PlanetModel planetModel, Bounds bounds) Get the bounds for a segment endpoint.inthashCode()booleanintersects(GeoShape geoShape) Determine if this endpoint intersects a GeoShape.booleanintersects(PlanetModel planetModel, Plane p, GeoPoint[] notablePoints, Membership[] bounds) Determine if this endpoint intersects a specified plane.booleanisWithin(double x, double y, double z) Check if point is within this endpoint.booleanCheck if point is within this endpoint.doublenearestPathDistance(DistanceStyle distanceStyle, double x, double y, double z) Compute nearest path distance.doubleoutsideDistance(DistanceStyle distanceStyle, double x, double y, double z) Compute external distance.doublepathCenterDistance(DistanceStyle distanceStyle, double x, double y, double z) Compute path center distance.doublepathDeltaDistance(DistanceStyle distanceStyle, double x, double y, double z) Compute delta path distance.doublepathDistance(DistanceStyle distanceStyle, double x, double y, double z) Compute interior path distance.toString()
-
Field Details
-
point
The center point of the endpoint -
NO_MEMBERSHIP
Null membership
-
-
Constructor Details
-
BaseSegmentEndpoint
-
-
Method Details
-
isWithin
Description copied from interface:GeoStandardPath.SegmentEndpointCheck if point is within this endpoint.- Specified by:
isWithinin interfaceGeoStandardPath.SegmentEndpoint- Parameters:
point- is the point.- Returns:
- true of within.
-
isWithin
public boolean isWithin(double x, double y, double z) Description copied from interface:GeoStandardPath.SegmentEndpointCheck if point is within this endpoint.- Specified by:
isWithinin interfaceGeoStandardPath.SegmentEndpoint- Parameters:
x- is the point x.y- is the point y.z- is the point z.- Returns:
- true of within.
-
pathDeltaDistance
Description copied from interface:GeoStandardPath.SegmentEndpointCompute delta path distance.- Specified by:
pathDeltaDistancein interfaceGeoStandardPath.SegmentEndpoint- Parameters:
distanceStyle- is the distance style.x- is the point x.y- is the point y.z- is the point z.- Returns:
- the distance metric, in aggregation form.
-
pathDistance
Description copied from interface:GeoStandardPath.SegmentEndpointCompute interior path distance.- Specified by:
pathDistancein interfaceGeoStandardPath.SegmentEndpoint- Parameters:
distanceStyle- is the distance style.x- is the point x.y- is the point y.z- is the point z.- Returns:
- the distance metric, in aggregation form.
-
nearestPathDistance
Description copied from interface:GeoStandardPath.SegmentEndpointCompute nearest path distance.- Specified by:
nearestPathDistancein interfaceGeoStandardPath.SegmentEndpoint- Parameters:
distanceStyle- is the distance style.x- is the point x.y- is the point y.z- is the point z.- Returns:
- the distance metric (always value zero), in aggregation form, or POSITIVE_INFINITY if the point is not within the bounds of the endpoint.
-
pathCenterDistance
Description copied from interface:GeoStandardPath.SegmentEndpointCompute path center distance.- Specified by:
pathCenterDistancein interfaceGeoStandardPath.SegmentEndpoint- Parameters:
distanceStyle- is the distance style.x- is the point x.y- is the point y.z- is the point z.- Returns:
- the distance metric, or POSITIVE_INFINITY if the point is not within the bounds of the endpoint.
-
outsideDistance
Description copied from interface:GeoStandardPath.SegmentEndpointCompute external distance.- Specified by:
outsideDistancein interfaceGeoStandardPath.SegmentEndpoint- Parameters:
distanceStyle- is the distance style.x- is the point x.y- is the point y.z- is the point z.- Returns:
- the distance metric.
-
intersects
public boolean intersects(PlanetModel planetModel, Plane p, GeoPoint[] notablePoints, Membership[] bounds) Description copied from interface:GeoStandardPath.SegmentEndpointDetermine if this endpoint intersects a specified plane.- Specified by:
intersectsin interfaceGeoStandardPath.SegmentEndpoint- Parameters:
planetModel- is the planet model.p- is the plane.notablePoints- are the points associated with the plane.bounds- are any bounds which the intersection must lie within.- Returns:
- true if there is a matching intersection.
-
intersects
Description copied from interface:GeoStandardPath.SegmentEndpointDetermine if this endpoint intersects a GeoShape.- Specified by:
intersectsin interfaceGeoStandardPath.SegmentEndpoint- Parameters:
geoShape- is the GeoShape.- Returns:
- true if there is shape intersect this endpoint.
-
getBounds
Description copied from interface:GeoStandardPath.SegmentEndpointGet the bounds for a segment endpoint.- Specified by:
getBoundsin interfaceGeoStandardPath.SegmentEndpoint- Parameters:
planetModel- is the planet model.bounds- are the bounds to be modified.
-
equals
-
hashCode
public int hashCode() -
toString
-