Package matchedTemplateClassifer
Class MTClassifierControl
java.lang.Object
PamController.PamControlledUnit
matchedTemplateClassifer.MTClassifierControl
- All Implemented Interfaces:
 ClickTypeProvider,PamSettings,SettingsNameProvider
public class MTClassifierControl
extends PamControlledUnit
implements PamSettings, ClickTypeProvider
Classifier which classifies clicks.
- Author:
 - Jamie Macaulay
 
- 
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intFlag to indicate a setup is requiredstatic final intstatic final intFlag for processing startFields inherited from class PamController.PamControlledUnit
isMixed, isViewer - 
Constructor Summary
Constructors - 
Method Summary
Modifier and TypeMethodDescriptionintcodeToListIndex(int code) Returns the index in the list for the click type.createDetectionMenu(Frame parentFrame) Create a JMenu object containing MenuItems associated with PamProcessesint[]Returns a list of the currently-defined click types / species codes.getGUI(int flag) Get the GUI for the PAMControlled unit.Get params for the controlled unit.Get the MT process.The offline MT process.Convenience function to get parent data blockGet the settings pane.longString[]Get a list of species names.getSymbolData(byte clickType) Returns the symbol data for a classification type.Get a list of symbols for each species corresponding to getSpeciesList.voidnotifyModelChanged(int changeType) General notification when the PAMGAURD model changes.booleanrestoreSettings(PamControlledUnitSettings pamControlledUnitSettings) voidsetMTParams(MatchedTemplateParams newParams) voidCurrently the click detector has an integrated classifier and click detection type flags are integrated into this.voidcalled for all PamControlledUnits after all units have been created.voidshowSettingsDialog(Frame parentFrame) Show settings dialog.voidupdate(int processingFlag) Called whenever offline processing is occurringMethods inherited from class PamController.PamControlledUnit
addOfflineTaskGroup, addOtherRelatedMenuItems, addPamProcess, addPamProcess, addRelatedMenuItems, canClose, canPlayViewerSound, createDisplayMenu, createFileMenu, createHelpMenu, flushDataBlockBuffers, getBackupInformation, getFrameNumber, 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, getVerboseLevel, gotoTab, isInMainConfiguration, isNetRx, isViewer, pamClose, pamHasStopped, pamToStart, playViewerSound, removePamProcess, removeUnit, rename, saveViewerData, setFrameNumber, setModuleStatusManager, setPamConfiguration, setPamController, setPamModuleInfo, setPamView, setSidePanel, setTabPanel, setToolbarComponent, setUnitTaskManager, 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.SettingsNameProvider
getUnitName 
- 
Field Details
- 
PROCESSING_START
public static final int PROCESSING_STARTFlag for processing start- See Also:
 
 - 
NEW_PARAMS
public static final int NEW_PARAMSFlag to indicate a setup is required- See Also:
 
 - 
PROCESSING_END
public static final int PROCESSING_END- See Also:
 
 
 - 
 - 
Constructor Details
- 
MTClassifierControl
 
 - 
 - 
Method Details
- 
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
 - 
setupClickClassifier
public void setupClickClassifier()Currently the click detector has an integrated classifier and click detection type flags are integrated into this. Therefore to properly display flags in the click detectior display and generic time base displays a classifer needs to be set up in the click detector. This is a bit of a HACK for now. Currently we set the flag of this classifier to 101. - 
showSettingsDialog
Show settings dialog.- Parameters:
 parentFrame- - the frame.
 - 
setupControlledUnit
public void setupControlledUnit()Description copied from class:PamControlledUnitcalled for all PamControlledUnits after all units have been created. This is a good time for the controlled units and processes to find and check their source data and the configuration generally since most onjects (i.e. output data blocks) should be in place- Overrides:
 setupControlledUnitin classPamControlledUnit
 - 
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.
 
 - 
getSettingsPane
Get the settings pane.- Returns:
 - the settings pane.
 
 - 
getMTParams
Get params for the controlled unit.- Returns:
 - the params.
 
 - 
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
 
 - 
getUnitType
- Specified by:
 getUnitTypein interfacePamSettings- Overrides:
 getUnitTypein classPamControlledUnit- Returns:
 - A Name specific to the type, e.g. Click detector
 
 - 
getSettingsReference
- Specified by:
 getSettingsReferencein interfacePamSettings- Returns:
 - The serialisable object that will be stored
 
 - 
getParentDataBlock
Convenience function to get parent data block- Returns:
 - the parent data block.
 
 - 
getMTProcess
Get the MT process.- Returns:
 - the MT process.
 
 - 
update
public void update(int processingFlag) Called whenever offline processing is occurring- Parameters:
 processingFlag-
 - 
getSymbolData
Returns the symbol data for a classification type. If the type does not match the current type then null is returned.- Parameters:
 clickType- - the click type.- Returns:
 - symbol data for the click type.
 
 - 
getSpeciesList
Description copied from interface:ClickTypeProviderGet a list of species names.- Specified by:
 getSpeciesListin interfaceClickTypeProvider- Returns:
 - list speces names.
 
 - 
getCodeList
public int[] getCodeList()Description copied from interface:ClickTypeProviderReturns a list of the currently-defined click types / species codes.- Specified by:
 getCodeListin interfaceClickTypeProvider- Returns:
 - int array with the codes
 
 - 
codeToListIndex
public int codeToListIndex(int code) Description copied from interface:ClickTypeProviderReturns the index in the list for the click type.- Specified by:
 codeToListIndexin interfaceClickTypeProvider- Parameters:
 code- - the click type code- Returns:
 - the index.
 
 - 
getSymbolsData
Description copied from interface:ClickTypeProviderGet a list of symbols for each species corresponding to getSpeciesList.- Specified by:
 getSymbolsDatain interfaceClickTypeProvider- Returns:
 - list of species symbols.
 
 - 
getOfflineMTProcess
The offline MT process.- Returns:
 - the offline mt process.
 
 - 
setMTParams
 - 
getGUI
Get the GUI for the PAMControlled unit. This has multiple GUI options which are instantiated depending on the view type.- Overrides:
 getGUIin classPamControlledUnit- Parameters:
 flag- . The GUI type flag defined in PAMGuiManager.- Returns:
 - the GUI for the PamControlledUnit unit.
 
 
 -