public class GeometryAssert extends Object
| Modifier and Type | Method and Description |
|---|---|
static void |
assertAllCurveSegmentsHaveRequiredLength(Element gmlCurve)
Asserts that the number of direct positions in the posList element
appearing within each segment of the given curve geometry satisfies the
minimum length requirements.
|
static void |
assertCoordinateEquals(com.vividsolutions.jts.geom.Coordinate actualPos,
com.vividsolutions.jts.geom.Coordinate expectedPos,
int tolerancePPM,
String message)
Asserts that the given Coordinate tuples are equal within the specified
tolerance.
|
static void |
assertCurveComponentsAreConnected(Element gmlCurve)
Asserts that the components of a composite curve are connected; that is,
the orientation of the curve members is such that each component (except
the first) begins where the preceding one ends.
|
static void |
assertCurveSegmentsAreConnected(Element gmlCurve)
Asserts that all segments of a curve are connected; that is, the end
point of each segment (except the last) is identical to the start point
of the next segment.
|
static void |
assertGeometryCoveredByValidArea(org.geotoolkit.gml.xml.v321.AbstractGeometryType gmlGeom)
Asserts that the given geometry element is covered by the valid area of
its associated CRS.
|
static void |
assertValidCRS(Element geom)
Asserts that the given geometry element has a valid CRS reference.
|
static void |
assertValidSurfaceBoundary(Element surfaceElem)
Asserts that the boundary of the given surface is topologically correct.
|
(package private) static void |
assertValidSurfaceOrientation(Element surfaceElem)
Asserts that the boundary of the given surface is correctly oriented with
respect to the upward normal.
|
(package private) static void |
removeConsecutiveDuplicates(List<com.vividsolutions.jts.geom.Coordinate> coordList,
double tolerancePPM) |
public static void assertValidCRS(Element geom)
geom - A DOM Element node representing a GML geometry element (or an
element that can be substituted for one).public static void assertGeometryCoveredByValidArea(org.geotoolkit.gml.xml.v321.AbstractGeometryType gmlGeom)
WARNING: May be problematic for 3D coordinates.
gmlGeom - A GML geometry element.public static void assertAllCurveSegmentsHaveRequiredLength(Element gmlCurve)
size(posList) % dimCRS = 0.gmlCurve - An Element node representing a GML curve geometry (gml:Curve
or gml:LineString)public static void assertCurveSegmentsAreConnected(Element gmlCurve)
gmlCurve - An Element node representing a gml:Curve element.public static void assertCurveComponentsAreConnected(Element gmlCurve)
gmlCurve - An Element node representing a gml:CompositeCurve element.public static void assertCoordinateEquals(com.vividsolutions.jts.geom.Coordinate actualPos,
com.vividsolutions.jts.geom.Coordinate expectedPos,
int tolerancePPM,
String message)
actualPos - The actual position.expectedPos - The expected position.tolerancePPM - The maximum tolerable difference between tuple elements,
expressed in parts per million (ppm).message - The assertion error message.public static void assertValidSurfaceBoundary(Element surfaceElem)
surfaceElem - A DOM Element node representing a surface geometry
(substitutes for gml:AbstractSurface).static void assertValidSurfaceOrientation(Element surfaceElem)
surfaceElem - A DOM Element node representing a surface geometry
(substitutes for gml:AbstractSurface).static void removeConsecutiveDuplicates(List<com.vividsolutions.jts.geom.Coordinate> coordList, double tolerancePPM)
Copyright © 2023 Open Geospatial Consortium. All rights reserved.