Class MultiSearch
- java.lang.Object
-
- adams.core.logging.LoggingObject
-
- adams.core.logging.CustomLoggingLevelObject
-
- adams.core.option.AbstractOptionHandler
-
- adams.flow.source.filesystemsearch.AbstractFileSystemSearchlet
-
- adams.flow.source.filesystemsearch.MultiSearch
-
- All Implemented Interfaces:
Destroyable
,GlobalInfoSupporter
,LoggingLevelHandler
,LoggingSupporter
,OptionHandler
,QuickInfoSupporter
,ShallowCopySupporter<AbstractFileSystemSearchlet>
,SizeOfHandler
,Stoppable
,StoppableWithFeedback
,FlowContextHandler
,Serializable
public class MultiSearch extends AbstractFileSystemSearchlet
Combines the search results of multiple search algorithms.
-logging-level <OFF|SEVERE|WARNING|INFO|CONFIG|FINE|FINER|FINEST> (property: loggingLevel) The logging level for outputting errors and debugging output. default: WARNING
-search <adams.flow.source.filesystemsearch.AbstractFileSystemSearchlet> [-search ...] (property: searches) The search algorithms to execute. default:
- Version:
- $Revision$
- Author:
- fracpete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected AbstractFileSystemSearchlet[]
m_Searches
the search algorithms to execute.-
Fields inherited from class adams.flow.source.filesystemsearch.AbstractFileSystemSearchlet
m_FlowContext, m_Stopped
-
Fields inherited from class adams.core.option.AbstractOptionHandler
m_OptionManager
-
Fields inherited from class adams.core.logging.LoggingObject
m_Logger, m_LoggingIsEnabled, m_LoggingLevel
-
-
Constructor Summary
Constructors Constructor Description MultiSearch()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
check()
Performs a setup check before search.void
defineOptions()
Adds options to the internal list of options.protected List<String>
doSearch()
Performs the actual search.AbstractFileSystemSearchlet[]
getSearches()
Returns the search algorithms in use.String
globalInfo()
Returns a string describing the object.String
searchesTipText()
Returns the tip text for this property.void
setFlowContext(Actor value)
Sets the flow context.void
setSearches(AbstractFileSystemSearchlet[] value)
Sets the search algorithms to use.void
stopExecution()
Stops the execution.-
Methods inherited from class adams.flow.source.filesystemsearch.AbstractFileSystemSearchlet
getFlowContext, getQuickInfo, isStopped, search, shallowCopy, shallowCopy
-
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, destroy, finishInit, getDefaultLoggingLevel, getOptionManager, initialize, loggingLevelTipText, newOptionManager, reset, setLoggingLevel, toCommandLine, toString
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface adams.core.logging.LoggingLevelHandler
getLoggingLevel
-
-
-
-
Field Detail
-
m_Searches
protected AbstractFileSystemSearchlet[] m_Searches
the search algorithms to execute.
-
-
Method Detail
-
globalInfo
public String globalInfo()
Returns a string describing the object.- Specified by:
globalInfo
in interfaceGlobalInfoSupporter
- Specified by:
globalInfo
in classAbstractOptionHandler
- Returns:
- a description suitable for displaying in the gui
-
defineOptions
public void defineOptions()
Adds options to the internal list of options.- Specified by:
defineOptions
in interfaceOptionHandler
- Overrides:
defineOptions
in classAbstractOptionHandler
-
setSearches
public void setSearches(AbstractFileSystemSearchlet[] value)
Sets the search algorithms to use.- Parameters:
value
- the algorithms
-
getSearches
public AbstractFileSystemSearchlet[] getSearches()
Returns the search algorithms in use.- Returns:
- the algorithms
-
searchesTipText
public String searchesTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setFlowContext
public void setFlowContext(Actor value)
Sets the flow context.- Specified by:
setFlowContext
in interfaceFlowContextHandler
- Overrides:
setFlowContext
in classAbstractFileSystemSearchlet
- Parameters:
value
- the actor
-
check
protected void check() throws Exception
Performs a setup check before search.- Overrides:
check
in classAbstractFileSystemSearchlet
- Throws:
Exception
- if checks failed
-
doSearch
protected List<String> doSearch() throws Exception
Performs the actual search.- Specified by:
doSearch
in classAbstractFileSystemSearchlet
- Returns:
- the search result
- Throws:
Exception
- if search failed
-
stopExecution
public void stopExecution()
Stops the execution.- Specified by:
stopExecution
in interfaceStoppable
- Specified by:
stopExecution
in classAbstractFileSystemSearchlet
-
-