Package org.locationtech.jts.io
Class WKBHexFileReader
- java.lang.Object
-
- org.locationtech.jts.io.WKBHexFileReader
-
-
Constructor Summary
Constructors Constructor Description WKBHexFileReader(File file, WKBReader wkbReader)
Creates a new WKBHexFileReader given the File to read from and a WKTReader to use to parse the geometries.WKBHexFileReader(Reader reader, WKBReader wkbReader)
Creates a new WKBHexFileReader, given aReader
to read from.WKBHexFileReader(String filename, WKBReader wkbReader)
Creates a new WKBHexFileReader, given the name of the file to read from.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List
read()
Reads a sequence of geometries.void
setLimit(int limit)
Sets the maximum number of geometries to read.void
setOffset(int offset)
Sets the number of geometries to skip before storing.
-
-
-
Constructor Detail
-
WKBHexFileReader
public WKBHexFileReader(File file, WKBReader wkbReader)
Creates a new WKBHexFileReader given the File to read from and a WKTReader to use to parse the geometries.- Parameters:
file
- the File to read fromwkbReader
- the geometry reader to use
-
WKBHexFileReader
public WKBHexFileReader(String filename, WKBReader wkbReader)
Creates a new WKBHexFileReader, given the name of the file to read from.- Parameters:
filename
- the name of the file to read fromwkbReader
- the geometry reader to use
-
-
Method Detail
-
setLimit
public void setLimit(int limit)
Sets the maximum number of geometries to read.- Parameters:
limit
- the maximum number of geometries to read
-
setOffset
public void setOffset(int offset)
Sets the number of geometries to skip before storing.- Parameters:
offset
- the number of geometries to skip
-
read
public List read() throws IOException, ParseException
Reads a sequence of geometries. If an offset is specified, geometries read up to the offset count are skipped. If a limit is specified, no more than limit geometries are read.- Returns:
- the list of geometries read
- Throws:
IOException
- if an I/O exception was encounteredParseException
- if an error occurred reading a geometry
-
-