public class PreparedGeometryOperation extends java.lang.Object implements GeometryOperation
GeometryOperation
which uses PreparedGeometry
s
for applicable operations.
This allows testing correctness of the PreparedGeometry implementation.
This class can be used via the -geomop command-line option or by the <geometryOperation> XML test file setting.
Modifier and Type | Class and Description |
---|---|
(package private) static class |
PreparedGeometryOperation.PreparedGeometryOp |
Modifier and Type | Field and Description |
---|---|
private GeometryMethodOperation |
chainOp |
Constructor and Description |
---|
PreparedGeometryOperation() |
PreparedGeometryOperation(GeometryMethodOperation chainOp)
Creates a new operation which chains to the given
GeometryMethodOperation
for non-intercepted methods. |
Modifier and Type | Method and Description |
---|---|
java.lang.Class |
getReturnType(java.lang.String opName)
Gets the class of the return type of the given operation.
|
Result |
invoke(java.lang.String opName,
Geometry geometry,
java.lang.Object[] args)
Invokes the named operation
|
private Result |
invokePreparedOp(java.lang.String opName,
Geometry geometry,
java.lang.Object[] args) |
private static boolean |
isPreparedOp(java.lang.String opName) |
private GeometryMethodOperation chainOp
public PreparedGeometryOperation()
public PreparedGeometryOperation(GeometryMethodOperation chainOp)
GeometryMethodOperation
for non-intercepted methods.chainOp
- the operation to chain topublic java.lang.Class getReturnType(java.lang.String opName)
GeometryOperation
getReturnType
in interface GeometryOperation
opName
- the name of the operationprivate static boolean isPreparedOp(java.lang.String opName)
public Result invoke(java.lang.String opName, Geometry geometry, java.lang.Object[] args) throws java.lang.Exception
invoke
in interface GeometryOperation
opName
- geometry
- args
- java.lang.Exception
GeometryOperation.invoke(java.lang.String, org.locationtech.jts.geom.Geometry, java.lang.Object[])