Class IOUtil
- java.lang.Object
-
- com.vividsolutions.jtstest.util.io.IOUtil
-
public class IOUtil extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description IOUtil()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static GeometryreadFile(java.lang.String filename, GeometryFactory geomFact)static GeometryreadGeoJSONString(java.lang.String s, GeometryFactory geomFact)static GeometryreadGMLString(java.lang.String gml, GeometryFactory geomFact)static GeometryreadWKBHexString(java.lang.String wkb, GeometryFactory geomFact)static GeometryreadWKTString(java.lang.String wkt, GeometryFactory geomFact)Reads one or more WKT geometries from a string.
-
-
-
Method Detail
-
readFile
public static Geometry readFile(java.lang.String filename, GeometryFactory geomFact) throws java.lang.Exception, java.io.IOException
- Throws:
java.lang.Exceptionjava.io.IOException
-
readWKTString
public static Geometry readWKTString(java.lang.String wkt, GeometryFactory geomFact) throws ParseException, java.io.IOException
Reads one or more WKT geometries from a string.- Parameters:
wkt-geomFact-- Returns:
- the geometry read
- Throws:
ParseExceptionjava.io.IOException
-
readWKBHexString
public static Geometry readWKBHexString(java.lang.String wkb, GeometryFactory geomFact) throws ParseException, java.io.IOException
- Throws:
ParseExceptionjava.io.IOException
-
readGMLString
public static Geometry readGMLString(java.lang.String gml, GeometryFactory geomFact) throws ParseException, java.io.IOException, org.xml.sax.SAXException, javax.xml.parsers.ParserConfigurationException
- Throws:
ParseExceptionjava.io.IOExceptionorg.xml.sax.SAXExceptionjavax.xml.parsers.ParserConfigurationException
-
readGeoJSONString
public static Geometry readGeoJSONString(java.lang.String s, GeometryFactory geomFact) throws ParseException
- Throws:
ParseException
-
-