Package org.h2gis.functions.io.asc
Class AscRead
- java.lang.Object
-
- org.h2gis.api.AbstractFunction
-
- org.h2gis.functions.io.asc.AscRead
-
- All Implemented Interfaces:
org.h2gis.api.Function,org.h2gis.api.ScalarFunction
public class AscRead extends org.h2gis.api.AbstractFunction implements org.h2gis.api.ScalarFunctionSQL function to import ESRI ASCII Raster file as points or polygons table.- Author:
- Nicolas Fortin (Université Gustave Eiffel 2020)
-
-
Constructor Summary
Constructors Constructor Description AscRead()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetJavaStaticMethod()static voidreadAscii(Connection connection, String fileName)Read the ASCII file.static voidreadAscii(Connection connection, String fileName, String tableReference, org.h2.value.Value option)Read the ASCII file.static voidreadAscii(Connection connection, String fileName, String tableReference, org.locationtech.jts.geom.Geometry envelope, int downScale, boolean extractAsPolygons)Import a small subset of ASC file.static voidreadAscii(Connection connection, String fileName, String tableReference, org.locationtech.jts.geom.Geometry envelope, int downScale, boolean extractAsPolygons, boolean deleteTable)Import a small subset of ASC file.static voidreadAscii(Connection connection, String fileName, String tableReference, org.locationtech.jts.geom.Geometry envelope, int downScale, boolean extractAsPolygons, boolean deleteTable, String encoding, int zType)Import a small subset of ASC file.static voidreadAscii(Connection connection, String fileName, org.h2.value.Value option)Read the ASCII file.-
Methods inherited from class org.h2gis.api.AbstractFunction
addProperty, getProperty, removeProperty
-
-
-
-
Method Detail
-
getJavaStaticMethod
public String getJavaStaticMethod()
- Specified by:
getJavaStaticMethodin interfaceorg.h2gis.api.ScalarFunction
-
readAscii
public static void readAscii(Connection connection, String fileName) throws IOException, SQLException
Read the ASCII file.- Parameters:
connection-fileName-- Throws:
IOExceptionSQLException
-
readAscii
public static void readAscii(Connection connection, String fileName, org.h2.value.Value option) throws IOException, SQLException
Read the ASCII file.- Parameters:
connection-fileName-option-- Throws:
IOExceptionSQLException
-
readAscii
public static void readAscii(Connection connection, String fileName, String tableReference, org.h2.value.Value option) throws IOException, SQLException
Read the ASCII file.- Parameters:
connection-fileName-tableReference-option-- Throws:
IOExceptionSQLException
-
readAscii
public static void readAscii(Connection connection, String fileName, String tableReference, org.locationtech.jts.geom.Geometry envelope, int downScale, boolean extractAsPolygons) throws IOException, SQLException
Import a small subset of ASC file.- Parameters:
connection-fileName-tableReference-envelope- Extract only pixels that intersects the provided geometry envelope, null to disable filterdownScale- Coefficient used for exporting less cells (1 all cells, 2 for size / 2)extractAsPolygons- If true pixels are converted to polygon. (default false)- Throws:
IOExceptionSQLException
-
readAscii
public static void readAscii(Connection connection, String fileName, String tableReference, org.locationtech.jts.geom.Geometry envelope, int downScale, boolean extractAsPolygons, boolean deleteTable) throws IOException, SQLException
Import a small subset of ASC file.- Parameters:
connection-fileName-tableReference-envelope- Extract only pixels that intersects the provided geometry envelope, null to disable filterdownScale- Coefficient used for exporting less cells (1 all cells, 2 for size / 2)extractAsPolygons- If true pixels are converted to polygon. (default false)- Throws:
IOExceptionSQLException
-
readAscii
public static void readAscii(Connection connection, String fileName, String tableReference, org.locationtech.jts.geom.Geometry envelope, int downScale, boolean extractAsPolygons, boolean deleteTable, String encoding, int zType) throws IOException, SQLException
Import a small subset of ASC file.- Parameters:
connection-fileName-tableReference-envelope- Extract only pixels that intersects the provided geometry envelope, null to disable filterdownScale- Coefficient used for exporting less cells (1 all cells, 2 for size / 2)extractAsPolygons- If true pixels are converted to polygon. (default false)- Throws:
IOExceptionSQLException
-
-