public class CoordinateWithinTolerancePointEquality extends Object
PointEquality that considers Points to be equal when their coordinates
are within a specified tolerance of each other.| Constructor and Description |
|---|
CoordinateWithinTolerancePointEquality(DimensionalFlag dimensionalFlag,
double tolerance)
Constructs an instance
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(double[] first,
DimensionalFlag df1,
double[] second,
DimensionalFlag df2)
Tests whether the specified coordinates represent the same point.
|
protected boolean |
equals(double co1,
double co2) |
boolean |
equals(Point first,
Point second)
Tests whether the specified
Points are equal. |
protected double |
get(double[] coordinates,
int index) |
protected DimensionalFlag |
getDimensionalFlag() |
public CoordinateWithinTolerancePointEquality(DimensionalFlag dimensionalFlag, double tolerance)
dimensionalFlag - specifies the dimensions that will be considered in the equality checktolerance - the tolerance within which coordinates are considered equalprotected boolean equals(double co1,
double co2)
public boolean equals(Point first, Point second)
Points are equal.equals in interface PointEqualityfirst - first Pointsecond - second PointPoint.public boolean equals(double[] first,
DimensionalFlag df1,
double[] second,
DimensionalFlag df2)
The coordinates are assumed to be in the same Coordinate Reference System.
equals in interface PointEqualityfirst - the coordinates of the first Pointdf1 - the DimensionalFlag for the first coordinate arraysecond - the coordinates second Point to testdf2 - the DimensionalFlag for the second coordinate arrayPoints represented by the coordinates are equalprotected double get(double[] coordinates,
int index)
protected DimensionalFlag getDimensionalFlag()
Copyright © 2015 geolatte.org. All rights reserved.