Package fileOfflineData
Class OfflineFileControl
java.lang.Object
PamController.PamControlledUnit
fileOfflineData.OfflineFileControl
- All Implemented Interfaces:
 OfflineDataStore,SettingsNameProvider
- Direct Known Subclasses:
 CPODControl,D3Control
- 
Field Summary
FieldsFields inherited from class PamController.PamControlledUnit
isMixed, isViewer - 
Constructor Summary
Constructors - 
Method Summary
Modifier and TypeMethodDescriptioncreateDetectionMenu(Frame parentFrame) Create a JMenu object containing MenuItems associated with PamProcessesprotected abstract PamDataBlockcreateOfflineDataBlock(OfflineFileProcess offlineFileProcess) Get the datablock - need to be abstract so that it can be created for specific types in the concrete classes.voidcreateOfflineDataMap(Window parentFrame) Create a basic map of the data including first and last times and some kind of data/unit time count plus ideally some kind of start and stop time list of where there are gaps in the data.voiddetectionMenuAction(Frame parentFrame) Get the data location.Get the data source nameprotected abstract StringGet the file type for the files to be listedabstract booleanloadData(PamDataBlock dataBlock, ArrayList<OfflineFileMapPoint> usedMapPoints, OfflineDataLoadInfo offlineDataLoadInfo, ViewLoadObserver loadObserver) Load data from the files and pack into appropriate datablocks.booleanloadData(PamDataBlock dataBlock, OfflineDataLoadInfo offlineDataLoadInfo, ViewLoadObserver loadObserver) Load data for a given datablock between two time limits.voidnotifyModelChanged(int changeType) General notification when the PAMGAURD model changes.protected abstract voidprocessMapFile(File aFile, int fileIndex) Called for each file when making the data map.booleanrewriteIndexFile(PamDataBlock dataBlock, OfflineDataMapPoint dmp) Moved this function over from binary data store.voidsetDatagramManager(DatagramManager datagramManager) voidsetFileParams(OfflineFileParams fileParams) Methods inherited from class PamController.PamControlledUnit
addOfflineTaskGroup, addOtherRelatedMenuItems, addPamProcess, addPamProcess, addRelatedMenuItems, canClose, canPlayViewerSound, createDisplayMenu, createFileMenu, createHelpMenu, flushDataBlockBuffers, getBackupInformation, getFrameNumber, getGUI, getGuiFrame, getInstanceIndex, getModuleStatus, getModuleStatusManager, getModuleSummary, getModuleSummary, getNumOfflineTaskGroups, getNumPamProcesses, getOfflineState, getOfflineTaskGroup, getPamConfiguration, getPamController, getPamModuleInfo, getPamProcess, getPamView, getPlugin, getShortUnitType, getSidePanel, getTabClipCopier, getTabPanel, getTabSpecificMenuBar, getToolbarComponent, getUnitName, getUnitTaskManager, getUnitTaskManager, getUnitType, getVerboseLevel, gotoTab, isInMainConfiguration, isNetRx, isViewer, pamClose, pamHasStopped, pamToStart, playViewerSound, removePamProcess, removeUnit, rename, saveViewerData, setFrameNumber, setModuleStatusManager, setPamConfiguration, setPamController, setPamModuleInfo, setPamView, setSidePanel, setTabPanel, setToolbarComponent, setUnitTaskManager, setupControlledUnit, stopViewerSound, tellModule, terminalPrint, terminalPrintln, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface PamController.OfflineDataStore
saveData 
- 
Field Details
- 
fileParams
 
 - 
 - 
Constructor Details
- 
OfflineFileControl
 
 - 
 - 
Method Details
- 
getDataLocation
Description copied from interface:OfflineDataStoreGet the data location. This may be a specific file, or might be a folder if data are in many files, a URI, etc.- Specified by:
 getDataLocationin interfaceOfflineDataStore- Returns:
 - store locations
 
 - 
notifyModelChanged
public void notifyModelChanged(int changeType) Description copied from class:PamControlledUnitGeneral notification when the PAMGAURD model changes.- Overrides:
 notifyModelChangedin classPamControlledUnit- Parameters:
 changeType- type of change
 - 
createOfflineDataMap
Description copied from interface:OfflineDataStoreCreate a basic map of the data including first and last times and some kind of data/unit time count plus ideally some kind of start and stop time list of where there are gaps in the data.- Specified by:
 createOfflineDataMapin interfaceOfflineDataStore
 - 
processMapFile
Called for each file when making the data map. Concrete class should examine the file and create a datamap point for whatever is in there.- Parameters:
 aFile-fileIndex-
 - 
getOfflineFileType
Get the file type for the files to be listed- Returns:
 - file type (e.g. xml)
 
 - 
createOfflineDataBlock
Get the datablock - need to be abstract so that it can be created for specific types in the concrete classes.- Parameters:
 offlineFileProcess2-- Returns:
 
 - 
getDataSourceName
Description copied from interface:OfflineDataStoreGet the data source name- Specified by:
 getDataSourceNamein interfaceOfflineDataStore- Returns:
 - data source name
 
 - 
createDetectionMenu
Description copied from class:PamControlledUnitCreate a JMenu object containing MenuItems associated with PamProcesses- Overrides:
 createDetectionMenuin classPamControlledUnit- Parameters:
 parentFrame- The owner frame of the menu- Returns:
 - reference to a JMenu which can be added to an existing menu or
         menu bar
         
Note that if multiple views are to use the same menu, then they should each create a new menu (by setting Create to true) the first time they call this method.
 
 - 
detectionMenuAction
 - 
getOfflineFileDataMap
- Returns:
 - the offlineFileDataMap
 
 - 
loadData
public boolean loadData(PamDataBlock dataBlock, OfflineDataLoadInfo offlineDataLoadInfo, ViewLoadObserver loadObserver) Description copied from interface:OfflineDataStoreLoad data for a given datablock between two time limits.- Specified by:
 loadDatain interfaceOfflineDataStore- Parameters:
 dataBlock- datablock owner of the dataloadObserver-- Returns:
 - true if load successful.
 
 - 
loadData
public abstract boolean loadData(PamDataBlock dataBlock, ArrayList<OfflineFileMapPoint> usedMapPoints, OfflineDataLoadInfo offlineDataLoadInfo, ViewLoadObserver loadObserver) Load data from the files and pack into appropriate datablocks.- Parameters:
 dataBlock- dataBlock for datausedMapPoints- list of mappoints which may have data in the load timeloadObserver- update observer for loading data.dataStart- start of data loaddataEnd- end of data loadcancellationObject- cancellation object for threading loading- Returns:
 - true hopefully !
 
 - 
getFileParams
- Returns:
 - the fileParams
 
 - 
getOfflineFileProcess
- Returns:
 - the offlineFileProcess
 
 - 
rewriteIndexFile
Description copied from interface:OfflineDataStoreMoved this function over from binary data store. Many storage systems may not be able to do this, but some might !- Specified by:
 rewriteIndexFilein interfaceOfflineDataStore- Parameters:
 dataBlock-dmp-- Returns:
 
 - 
getDatagramManager
- Specified by:
 getDatagramManagerin interfaceOfflineDataStore- Returns:
 - the datagramManager
 
 - 
setDatagramManager
- Parameters:
 datagramManager- the datagramManager to set
 - 
setFileParams
- Parameters:
 fileParams- the fileParams to set
 
 -