Package org.locationtech.jtstest.cmd
Class JTSOpCmd
java.lang.Object
org.locationtech.jtstest.cmd.JTSOpCmd
A CLI to run JTS TestBuilder operations.
Allows easier execution of JTS functions on test data for debugging purposes.
Examples:
--- Compute the area of a WKT geometry, output it jtsop -a some-file-with-geom.wkt -f txt area --- Validate geometries from a WKT file using limit and offset jtsop -a some-file-with-geom.wkt -limit 100 -offset 40 -f txt isValid --- Compute the unary union of a WKT geometry, output as WKB jtsop -a some-file-with-geom.wkt -f wkb Overlay.unaryUnion --- Compute the union of two geometries in WKT and WKB, output as WKT jtsop -a some-file-with-geom.wkt -b some-other-geom.wkb -f wkt Overlay.Union --- Compute the buffer of distance 10 of a WKT geometry, output as GeoJSON jtsop -a some-file-with-geom.wkt -f geojson Buffer.buffer 10 --- Compute the buffer of a literal geometry, output as WKT jtsop -a "POINT (10 10)" -f wkt Buffer.buffer 10 --- Compute buffers of multiple sizes jtsop -a "POINT (10 10)" -f wkt Buffer.buffer 1,10,100 --- Run op for each A jtsop -a "MULTIPOINT ((10 10), (20 20))" -eacha -f wkt Buffer.buffer --- Output a literal geometry as GeoJSON jtsop -a "POINT (10 10)" -f geojson
- Author:
- Martin Davis
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
void
String[]
static boolean
isFilename
(String arg) static void
void
replaceStdIn
(InputStream inStream)
-
Field Details
-
ERR_INVALID_ARG_PARAM
- See Also:
-
-
Constructor Details
-
JTSOpCmd
public JTSOpCmd()
-
-
Method Details
-
main
-
captureOutput
public void captureOutput() -
captureResult
public void captureResult() -
getResultGeometry
-
replaceStdIn
-
getOutput
-
getOutputLines
-
isFilename
-