Package likelihoodDetectionModule
Class LikelihoodDetectionParameters
java.lang.Object
likelihoodDetectionModule.LikelihoodDetectionParameters
- All Implemented Interfaces:
Serializable
,Cloneable
,ManagedParameters
public class LikelihoodDetectionParameters
extends Object
implements Serializable, Cloneable, ManagedParameters
The Class LikelihoodDetectionParameters provides the standard PamGuard
abstraction of system-save-able settings for a module. It is used by the
LikelihoodDetectionUnit (is-a PamControlledUnit) and returned by the
system's call to getParameters() when PamGuard wants to store its
persistent settings.
The LikelihoodDetectionParameters class is a farily deep and complicated
entity, so to make life within Java easier, it uses a deep copy technique
to make copies of itself via the deepCopy() method.
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionThe target configurations that have been configured for the module. -
Constructor Summary
ConstructorDescriptionInstantiates a new likelihood detection parameters object. -
Method Summary
Modifier and TypeMethodDescriptionboolean
Are configurations with errors scans the TargetConfigurations that are currently configured and returns a boolean value indicating whether any of them have erroneous values or are inconsistent with current acquisition (audio data source) settings.Configurations with errors returns the names of all of the TargetConfigurations that are currenly indicating errors.deepCopy()
Deep copy.Gets the acquisition settings that were used to configure the current likelihood detector configurations.int
Gets the channel map that was used to configure the current likelihood detector settings.Gets the configuration dialog settings that are used to have consistent user settings for the configuration dialog between program executions.Returns an ArrayList of LikelihoodFFTParameter objects indicating the currently active FFT processes that have been launched as a result of the TargetConfigurations.Get a set of data that describes all of the parameters in a classint
Gets the currently selected channels from the parameters.Gets the audio data (acquisition) source name used.void
setAcquisitionSettings
(AcquisitionSettings settings) Sets the acquisition settings were used to create the TargetConfigurations, but does NOT force a error-checking synchronization the way syncWithAcquisitionSettings() does.void
Sets the configuration dialog settings that are used to have consistent user settings for the configuration dialog between program executions.void
setSelectedChannels
(int selected) Sets the channels that are to be used from the audio data source.void
setSourceName
(String sourceName) Sets the source name for the audio data source (acquisition) to be used.void
syncWithAquisitionSettings
(AcquisitionSettings acquisitionSettings) Sync with aquisition settings.void
syncWithChannelMap
(int channelMap) Sync with channel map.
-
Field Details
-
targetConfigurations
The target configurations that have been configured for the module. This is made public just to make life a little easier. It isn't expected that encapsulation of this member is necessary.
-
-
Constructor Details
-
LikelihoodDetectionParameters
public LikelihoodDetectionParameters()Instantiates a new likelihood detection parameters object.
-
-
Method Details
-
deepCopy
Deep copy. The parameters object is sufficiently complex enough that a deep copy method utilizing a bytestream technique is helpful.- Returns:
- A copy of the likelihood detection parameters.
-
syncWithAquisitionSettings
Sync with aquisition settings. When a likelihood detection module is added and the persistent settings are read in, it is possible that the restored settings are not viable for the currently configured audio data source. This function takes in an likelihood AcquisitionSettings object and will check the stored parameters and flag any that are no longer functionable with respect to the settings. After this call is used, the function configurationsWithErrors() can be called to see if there are any target configurations that need adjustment or removal.- Parameters:
acquisitionSettings
- the acquisition settings
-
syncWithChannelMap
public void syncWithChannelMap(int channelMap) Sync with channel map. Separately, but similar to syncWithAcquisitionSettings(), the channel map alone can be adjusted between the current configurations and the current (changed) audio data settings.- Parameters:
channelMap
- the channel map
-
setAcquisitionSettings
Sets the acquisition settings were used to create the TargetConfigurations, but does NOT force a error-checking synchronization the way syncWithAcquisitionSettings() does.- Parameters:
settings
- the new acquisition settings
-
getAcquisitionSettings
Gets the acquisition settings that were used to configure the current likelihood detector configurations.- Returns:
- the acquisition settings
-
getChannelMap
public int getChannelMap()Gets the channel map that was used to configure the current likelihood detector settings.- Returns:
- the channel map
-
getSelectedChannels
public int getSelectedChannels()Gets the currently selected channels from the parameters.- Returns:
- the selected channels
-
setSelectedChannels
public void setSelectedChannels(int selected) Sets the channels that are to be used from the audio data source.- Parameters:
selected
- the new selected channels
-
getSourceName
Gets the audio data (acquisition) source name used.- Returns:
- the source name
-
setSourceName
Sets the source name for the audio data source (acquisition) to be used.- Parameters:
sourceName
- the new source name
-
areConfigurationsWithErrors
public boolean areConfigurationsWithErrors()Are configurations with errors scans the TargetConfigurations that are currently configured and returns a boolean value indicating whether any of them have erroneous values or are inconsistent with current acquisition (audio data source) settings.- Returns:
- true, iff all configurations are okay.
-
configurationsWithErrors
Configurations with errors returns the names of all of the TargetConfigurations that are currenly indicating errors.- Returns:
- the array listinvalid input: '<' string>
-
getFFTParameters
Returns an ArrayList of LikelihoodFFTParameter objects indicating the currently active FFT processes that have been launched as a result of the TargetConfigurations.- Returns:
- the fFT parameters
-
getConfigurationDialogSettings
Gets the configuration dialog settings that are used to have consistent user settings for the configuration dialog between program executions.- Returns:
- the configuration dialog settings
-
setConfigurationDialogSettings
Sets the configuration dialog settings that are used to have consistent user settings for the configuration dialog between program executions.- Parameters:
settings
- the new configuration dialog settings
-
getParameterSet
Description copied from interface:ManagedParameters
Get a set of data that describes all of the parameters in a class- Specified by:
getParameterSet
in interfaceManagedParameters
- Returns:
- description of the parameters in a class.
-