Class DaoGpsLog
- java.lang.Object
-
- org.hortonmachine.gears.io.geopaparazzi.geopap4.DaoGpsLog
-
public class DaoGpsLog extends Object
- Author:
- Andrea Antonello (www.hydrologis.com)
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classDaoGpsLog.GpsLogA gps log with an empty holder for gps data.static classDaoGpsLog.GpsPointA class representing a gps point.
-
Constructor Summary
Constructors Constructor Description DaoGpsLog()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidaddGpsLog(Connection connection, OmsGeopaparazziProject3To4Converter.GpsLog log, float width, String color, boolean visible)static voidaddGpsLogDataPoint(Connection connection, OmsGeopaparazziProject3To4Converter.GpsPoint point, long gpslogId)Adds a new XY entry to the gps table.static voidcollectDataForLog(IHMConnection connection, DaoGpsLog.GpsLog log)Gather gps points data for a supplied log.static voidcreateTables(Connection connection)Create log tables.static org.geotools.geometry.jts.ReferencedEnvelopegetEnvelope(IHMConnection connection)Get the current data envelope.static List<DaoGpsLog.GpsLog>getLogsList(IHMConnection connection)Get the list of available logs.
-
-
-
Method Detail
-
createTables
public static void createTables(Connection connection) throws IOException, SQLException
Create log tables.- Throws:
IOException- if something goes wrong.SQLException
-
addGpsLog
public static void addGpsLog(Connection connection, OmsGeopaparazziProject3To4Converter.GpsLog log, float width, String color, boolean visible) throws Exception
- Throws:
Exception
-
addGpsLogDataPoint
public static void addGpsLogDataPoint(Connection connection, OmsGeopaparazziProject3To4Converter.GpsPoint point, long gpslogId) throws Exception
Adds a new XY entry to the gps table.- Parameters:
connection- the db connection.point- the point to add.gpslogId- the id of the log the point is part of.- Throws:
IOException- if something goes wrongException
-
getLogsList
public static List<DaoGpsLog.GpsLog> getLogsList(IHMConnection connection) throws Exception
Get the list of available logs.- Parameters:
connection- the connection to use.- Returns:
- the list of logs.
- Throws:
SQLExceptionException
-
collectDataForLog
public static void collectDataForLog(IHMConnection connection, DaoGpsLog.GpsLog log) throws Exception
Gather gps points data for a supplied log.- Parameters:
connection- the connection to use.log- the log.- Throws:
Exception
-
getEnvelope
public static org.geotools.geometry.jts.ReferencedEnvelope getEnvelope(IHMConnection connection) throws Exception
Get the current data envelope.- Parameters:
connection- the db connection.- Returns:
- the envelope.
- Throws:
Exception
-
-