GPS
Class GpsLogger

java.lang.Object
  extended by generalDatabase.SQLLogging
      extended by GPS.GpsLogger

public class GpsLogger
extends SQLLogging


Field Summary
(package private)  PamTableItem dataStatus
           
(package private)  PamTableItem gpsDate
           
(package private)  int gpsDateCol
           
(package private)  PamTableItem gpsError
           
(package private)  PamTableItem gpsTime
           
(package private)  PamTableItem heading
           
(package private)  PamTableItem headingType
           
(package private)  PamTableItem latitude
           
(package private)  PamTableItem longitude
           
(package private)  PamTableItem magneticHeading
           
(package private)  PamTableItem magneticVariation
           
(package private)  PamTableItem pcTime
           
(package private)  PamTableItem speed
           
(package private)  PamTableItem speedType
           
(package private)  PamTableDefinition tableDefinition
           
(package private)  PamTableItem trueHeading
           
 
Fields inherited from class generalDatabase.SQLLogging
UPDATE_POLICY_OVERWRITE, UPDATE_POLICY_WRITENEW
 
Constructor Summary
GpsLogger(PamDataBlock pamDataBlock)
           
 
Method Summary
private  boolean convertLoggerGpsTable(DBProcess dbProcess, java.sql.Connection connection)
           
protected  boolean createDataUnit(long dataTime, int iD)
          Turn the data, which have been transferred back into the PamTableItems back into a useable data unit and put it into the datablock.
 boolean doExtraChecks(DBProcess dbProcess, java.sql.Connection connection)
          Gives each module a chance to do additional checks and alterations to the database table at connection time.
 boolean getCanLog()
           
private  boolean runStmt(java.sql.Connection con, java.lang.String str)
           
 void setTableData(PamDataUnit pamDataUnit)
          Callback function when new data are created that allows the user to set the data for each column.
 
Methods inherited from class generalDatabase.SQLLogging
createInClause, createViewResultSet, fillTableData, finalize, findLogger, getIdListUpdatClause, getLastTime, getPamDataBlock, getTableDefinition, getTimesUpdateClause, getUpdatePolicy, getViewerCursorFinder, getViewerLoadClause, getViewerUpdateClause, isCanView, isLoadViewData, loadViewData, loadViewerData, logData, prepareEmulation, prepareForMixedMode, readLastData, readMixedModeData, readNextEmulation, reCheckTable, reLogData, saveOfflineData, setCanView, setColumnData, setLoadViewData, setTableDefinition, setUpdatePolicy, transferDataFromResult
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

tableDefinition

PamTableDefinition tableDefinition

gpsDateCol

int gpsDateCol

gpsDate

PamTableItem gpsDate

pcTime

PamTableItem pcTime

gpsTime

PamTableItem gpsTime

latitude

PamTableItem latitude

longitude

PamTableItem longitude

speed

PamTableItem speed

speedType

PamTableItem speedType

heading

PamTableItem heading

headingType

PamTableItem headingType

gpsError

PamTableItem gpsError

dataStatus

PamTableItem dataStatus

trueHeading

PamTableItem trueHeading

magneticHeading

PamTableItem magneticHeading

magneticVariation

PamTableItem magneticVariation
Constructor Detail

GpsLogger

public GpsLogger(PamDataBlock pamDataBlock)
Method Detail

doExtraChecks

public boolean doExtraChecks(DBProcess dbProcess,
                             java.sql.Connection connection)
Description copied from class: SQLLogging
Gives each module a chance to do additional checks and alterations to the database table at connection time. e.g. the GPS module may want to check that the table is not an old Logger table and if necessary alter the columns into the PAMGUARD format.

Overrides:
doExtraChecks in class SQLLogging
Returns:
true if tests and alterations OK.

convertLoggerGpsTable

private boolean convertLoggerGpsTable(DBProcess dbProcess,
                                      java.sql.Connection connection)

runStmt

private boolean runStmt(java.sql.Connection con,
                        java.lang.String str)

setTableData

public void setTableData(PamDataUnit pamDataUnit)
Description copied from class: SQLLogging
Callback function when new data are created that allows the user to set the data for each column. Columns that have data which can be filled automatically (counters, primary keys and columns cross referenced to data in other tables) are filled automatically in fillTableData()

Specified by:
setTableData in class SQLLogging

createDataUnit

protected boolean createDataUnit(long dataTime,
                                 int iD)
Description copied from class: SQLLogging
Turn the data, which have been transferred back into the PamTableItems back into a useable data unit and put it into the datablock.

Overrides:
createDataUnit in class SQLLogging
Returns:
true if a data unit was sucessfully created

getCanLog

public boolean getCanLog()