Package tritechgemini.fileio
Class ECDFileCatalog
- All Implemented Interfaces:
Serializable
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intFields inherited from class tritechgemini.fileio.GeminiFileCatalog
ARISEND, DATEND, ECDEND, GLFEND -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanbuildCatalogue(ArrayList<ECDImageRecord> imageRecords) Catalogue the file.protected voidcheckDeserialisedCatalog(String filePath2) Called just after a catalogue object has been deserialised, giving the opportunity to check anything.booleanloadFullRecord(ECDImageRecord geminiRecord) fully load a record (if it isn't already).voidStop streaming the catalog.streamCatalog(CatalogStreamObserver streamObserver) Start a full forwards only read of the catalog from start to end, sending all records through to the streamObserver.Methods inherited from class tritechgemini.fileio.GeminiFileCatalog
analyseCatalog, cDateToMillis, createCatalogue, findRecordForIDandTime, findRecordForIndexandTime, findRecordIndex, findRelativeRecord, freeAllImageData, freeImageData, getCatalogException, getCatalogName, getFileCatalog, getFilePath, getFirstRecordTime, getFullRecord, getImageRecords, getLastRecordTime, getMaxSonarFrames, getNumRecords, getNumSonars, getRecord, getRecordByIndex, getRecordIndex, getSonarIDs, getSonarInfo, getSonarRecord, getTimeZone, readSerializedCatalog, setImageRecords, setTimeZone, timedLoadFullRecord, writeSerializedCatalog
-
Field Details
-
HEAD_VERSION
public static final int HEAD_VERSION- See Also:
-
HEAD_MSG
- See Also:
-
MASK_DEFAULT
public static final int MASK_DEFAULT- See Also:
-
MASK_TIS_QI
public static final int MASK_TIS_QI- See Also:
-
MASK_TIS_PA
public static final int MASK_TIS_PA- See Also:
-
MASK_TIS_SCAN
public static final int MASK_TIS_SCAN- See Also:
-
MASK_TIS_RB
public static final int MASK_TIS_RB- See Also:
-
MASK_TIS_TGT
public static final int MASK_TIS_TGT- See Also:
-
MASK_TIS_XYZ
public static final int MASK_TIS_XYZ- See Also:
-
MASK_TIS_SHRP
public static final int MASK_TIS_SHRP- See Also:
-
MASK_TIS_
public static final int MASK_TIS_- See Also:
-
-
Constructor Details
-
ECDFileCatalog
-
-
Method Details
-
buildCatalogue
Description copied from class:GeminiFileCatalogCatalogue the file. i.e. go through the file and get the times and file positions of every record in the file.- Specified by:
buildCataloguein classGeminiFileCatalog<ECDImageRecord>- Parameters:
imageRecords-- Returns:
- true if catalog created successfully
- Throws:
Exception
-
loadFullRecord
Description copied from class:GeminiFileCatalogfully load a record (if it isn't already). This may involve going back to the file and getting and unpacking the raw data.- Specified by:
loadFullRecordin classGeminiFileCatalog<ECDImageRecord>- Parameters:
geminiRecord-- Returns:
- true if load sucessful.
- Throws:
IOException
-
streamCatalog
public CatalogStreamSummary streamCatalog(CatalogStreamObserver streamObserver) throws CatalogException Description copied from class:GeminiFileCatalogStart a full forwards only read of the catalog from start to end, sending all records through to the streamObserver.Whatever calls this will almost definitely want to do so in a separate worker thread because the call will block until the read has finished.
- Specified by:
streamCatalogin classGeminiFileCatalog<ECDImageRecord>- Parameters:
streamObserver- observer to get catalog data.- Returns:
- number of records read.
- Throws:
CatalogException
-
stopCatalogStream
public void stopCatalogStream()Description copied from class:GeminiFileCatalogStop streaming the catalog.- Specified by:
stopCatalogStreamin classGeminiFileCatalog<ECDImageRecord>
-
checkDeserialisedCatalog
Description copied from class:GeminiFileCatalogCalled just after a catalogue object has been deserialised, giving the opportunity to check anything. note that the file path is set elsewhere to allow for the possibility that the absolute path to the file may have changed, so it's probably not necessary to do anything here.- Specified by:
checkDeserialisedCatalogin classGeminiFileCatalog<ECDImageRecord>- Parameters:
filePath2-
-