Package adams.data.multifilter
Class PickByIndex
- java.lang.Object
-
- adams.core.logging.LoggingObject
-
- adams.core.logging.CustomLoggingLevelObject
-
- adams.core.option.AbstractOptionHandler
-
- adams.data.multifilter.AbstractMultiSpectrumFilter
-
- adams.data.multifilter.PickByIndex
-
- All Implemented Interfaces:
adams.core.CleanUpHandler
,adams.core.Destroyable
,adams.core.GlobalInfoSupporter
,adams.core.logging.LoggingLevelHandler
,adams.core.logging.LoggingSupporter
,adams.core.option.OptionHandler
,adams.core.ShallowCopySupporter<AbstractMultiSpectrumFilter>
,adams.core.SizeOfHandler
,Serializable
,Comparable
public class PickByIndex extends AbstractMultiSpectrumFilter
Extracts the specified sub-spectrum.
-logging-level <OFF|SEVERE|WARNING|INFO|CONFIG|FINE|FINER|FINEST> (property: loggingLevel) The logging level for outputting errors and debugging output. default: WARNING
-no-id-update <boolean> (property: dontUpdateID) If enabled, suppresses updating the ID of adams.data.id.IDHandler data containers. default: false
-index <adams.core.Index> (property: index) The index of the spectrum to select. default: first example: An index is a number starting with 1; the following placeholders can be used as well: first, second, third, last_2, last_1, last
- Version:
- $Revision$
- Author:
- fracpete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected adams.core.Index
m_Index
the index of the spectrum to pick.-
Fields inherited from class adams.data.multifilter.AbstractMultiSpectrumFilter
m_DontUpdateID
-
-
Constructor Summary
Constructors Constructor Description PickByIndex()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
defineOptions()
Adds options to the internal list of options.adams.core.Index
getIndex()
Returns the index of the spectrum to select.String
globalInfo()
Returns a string describing the object.String
indexTipText()
Returns the tip text for this property.protected Spectrum
processData(MultiSpectrum data)
Performs the actual filtering.void
setIndex(adams.core.Index value)
Sets the index of the spectrum to select.-
Methods inherited from class adams.data.multifilter.AbstractMultiSpectrumFilter
checkData, cleanUp, compareTo, destroy, dontUpdateIDTipText, equals, filter, forCommandLine, forName, getDontUpdateID, getFilters, reset, setDontUpdateID, shallowCopy, shallowCopy
-
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, finishInit, getDefaultLoggingLevel, getOptionManager, initialize, loggingLevelTipText, newOptionManager, setLoggingLevel, toCommandLine, toString
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
-
-
-
Method Detail
-
globalInfo
public String globalInfo()
Returns a string describing the object.- Specified by:
globalInfo
in interfaceadams.core.GlobalInfoSupporter
- Specified by:
globalInfo
in classadams.core.option.AbstractOptionHandler
- 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 interfaceadams.core.option.OptionHandler
- Overrides:
defineOptions
in classAbstractMultiSpectrumFilter
-
setIndex
public void setIndex(adams.core.Index value)
Sets the index of the spectrum to select.- Parameters:
value
- the index
-
getIndex
public adams.core.Index getIndex()
Returns the index of the spectrum to select.- Returns:
- the index
-
indexTipText
public String indexTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
processData
protected Spectrum processData(MultiSpectrum data)
Performs the actual filtering.- Specified by:
processData
in classAbstractMultiSpectrumFilter
- Parameters:
data
- the data to filter- Returns:
- the filtered data, null if failed to generate output
-
-