Package binaryFileStorage.checker
Class BinaryUpdater
java.lang.Object
binaryFileStorage.checker.BinaryUpdater
- All Implemented Interfaces:
PamSettings,SettingsNameProvider
Functions for updating all binary files to the latest PAMGuard binary file version.
- Author:
- dg50
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet all datablocks in the model that have binary data.Get current binary storage folder.Get a list of selected datablocks.longbooleanbooleanrestoreSettings(PamControlledUnitSettings pamControlledUnitSettings) voidrunUpdate(UpdateWorkObserver updateObserver) voidsetBinaryUpdateParams(BinaryUpdateParams binaryUpdateParams) booleanShow the dialog that will control all the updating.voidStop the background process
-
Constructor Details
-
BinaryUpdater
-
-
Method Details
-
showDialog
public boolean showDialog()Show the dialog that will control all the updating.- Returns:
-
getBinaryDataBlocks
Get all datablocks in the model that have binary data.- Returns:
-
getSelectedDataBlocks
Get a list of selected datablocks.- Parameters:
params-- Returns:
-
getCurrentFolder
Get current binary storage folder.- Returns:
-
stopUpdate
public void stopUpdate()Stop the background process -
isRunning
public boolean isRunning() -
runUpdate
-
getBinaryUpdateParams
- Returns:
- the binaryUpdateParams
-
setBinaryUpdateParams
- Parameters:
binaryUpdateParams- the binaryUpdateParams to set
-
getUnitName
- Specified by:
getUnitNamein interfaceSettingsNameProvider- Returns:
- A Name specific to this instance of the particular class, e.g. Sperm whale detector, Beaked whale detector, etc.
-
getUnitType
- Specified by:
getUnitTypein interfacePamSettings- Returns:
- A Name specific to the type, e.g. Click detector
-
getSettingsReference
- Specified by:
getSettingsReferencein interfacePamSettings- Returns:
- The serialisable object that will be stored
-
getSettingsVersion
public long getSettingsVersion()- Specified by:
getSettingsVersionin interfacePamSettings- Returns:
- An integer version number for the settings
-
restoreSettings
- Specified by:
restoreSettingsin interfacePamSettings- Parameters:
pamControlledUnitSettings-- Returns:
- true if successful The object performs final checks (if needed) and then casts the settings data pamcontrolledunitSettings.settings into the correct type and uses as required
-