Package org.locationtech.jtstest.geomop
Class GeometryFunctionOperation
java.lang.Object
org.locationtech.jtstest.geomop.GeometryFunctionOperation
- All Implemented Interfaces:
GeometryOperation
Invokes a function from registry
or a Geometry method determined by a named operation with a list of arguments,
the first of which is a
Geometry
.
This class allows overriding Geometry methods
or augmenting them
with functions defined in a GeometryFunctionRegistry
.- Version:
- 1.7
- Author:
- Martin Davis
-
Constructor Summary
ConstructorsConstructorDescription -
Method Summary
-
Constructor Details
-
GeometryFunctionOperation
public GeometryFunctionOperation() -
GeometryFunctionOperation
-
-
Method Details
-
getReturnType
Description copied from interface:GeometryOperation
Gets the class of the return type of the given operation.- Specified by:
getReturnType
in interfaceGeometryOperation
- Parameters:
opName
- the name of the operation- Returns:
- the class of the return type of the specified operation
-
invoke
Description copied from interface:GeometryOperation
Invokes an operation on aGeometry
.- Specified by:
invoke
in interfaceGeometryOperation
- Parameters:
opName
- name of the operationgeometry
- the geometry to processargs
- the arguments to the operation (which may be typed as Strings)- Returns:
- the result of the operation
- Throws:
Exception
- if some error was encountered trying to find or process the operation
-