Package quickAnnotation.importAnnotation
Class QuickAnnotationImport
java.lang.Object
PamView.importData.DataImport<ArrayList<String>>
quickAnnotation.importAnnotation.QuickAnnotationImport
Class for importing streamer data from external file and saving to database.
.csv file format: name, streamerIndex, origin, Locator, time (excel datenum), xPos, yPos, zPos, xErr, yErr, zErr, heading, pitch, roll, lat, long. lat and long are optional. .csv import formats
List Format:
- Author:
- Jamie Macaulay
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptioncreateDataUnit
(ArrayList<String> dataLine) Create a data unit from the data loaded from the imported file.Get the data block to to save data to.String[]
Return the file extensions that can be loaded.boolean
isDataFormatOK
(ArrayList<String> dataLine) Check that a row of imported data is in the correct format.loadDataIntermediate
(String filePath) Loads the file into memory - each element of the output array list is then processed.boolean
Determine whether the streamer is going to be a threading or straight hydrophone and origin methodsdMethods inherited from class PamView.importData.DataImport
getDataUnitName
-
Constructor Details
-
QuickAnnotationImport
-
-
Method Details
-
loadDataIntermediate
Description copied from class:DataImport
Loads the file into memory - each element of the output array list is then processed.- Specified by:
loadDataIntermediate
in classDataImport<ArrayList<String>>
- Parameters:
filePath
- - the filepath.- Returns:
- a list of imported objects.
-
performPreChecks
public boolean performPreChecks()Determine whether the streamer is going to be a threading or straight hydrophone and origin methodsd- Overrides:
performPreChecks
in classDataImport<ArrayList<String>>
- Returns:
- true iof pre checks are OK.
-
isDataFormatOK
Description copied from class:DataImport
Check that a row of imported data is in the correct format.- Specified by:
isDataFormatOK
in classDataImport<ArrayList<String>>
- Parameters:
dataLine
- -a row of data loaded from file- Returns:
- true if the format is OK.
-
createDataUnit
Description copied from class:DataImport
Create a data unit from the data loaded from the imported file.- Specified by:
createDataUnit
in classDataImport<ArrayList<String>>
- Parameters:
dataLine
- -a row of data loaded from file- Returns:
- a data unit to be saved to the datablock.
-
getDataBlock
Description copied from class:DataImport
Get the data block to to save data to.- Specified by:
getDataBlock
in classDataImport<ArrayList<String>>
- Returns:
-
getExtensionsStrings
Description copied from class:DataImport
Return the file extensions that can be loaded.- Specified by:
getExtensionsStrings
in classDataImport<ArrayList<String>>
- Returns:
- an array of file extensions that can be loaded.
-