Class AbstractSampleIDExtraction
- java.lang.Object
-
- adams.core.logging.LoggingObject
-
- adams.core.logging.CustomLoggingLevelObject
-
- adams.core.option.AbstractOptionHandler
-
- adams.data.io.input.sampleidextraction.AbstractSampleIDExtraction
-
- All Implemented Interfaces:
adams.core.Destroyable
,adams.core.GlobalInfoSupporter
,adams.core.logging.LoggingLevelHandler
,adams.core.logging.LoggingSupporter
,adams.core.option.OptionHandler
,adams.core.SizeOfHandler
,SampleIDExtraction
,Serializable
public abstract class AbstractSampleIDExtraction extends adams.core.option.AbstractOptionHandler implements SampleIDExtraction
Ancestor for schemes that extract the sample ID from the filename.- Version:
- $Revision$
- Author:
- FracPete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description AbstractSampleIDExtraction()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected void
check(File file, Spectrum spec)
Performs checks before the actual extraction.protected abstract String
doExtract(File file, Spectrum spec)
Performs the actual extraction.String
extract(File file, Spectrum spec)
Performs the extraction.-
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, defineOptions, destroy, finishInit, getDefaultLoggingLevel, getOptionManager, globalInfo, initialize, loggingLevelTipText, newOptionManager, reset, setLoggingLevel, toCommandLine, toString
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
-
-
-
Method Detail
-
check
protected void check(File file, Spectrum spec)
Performs checks before the actual extraction.- Parameters:
file
- the current filespec
- the current spectrum
-
doExtract
protected abstract String doExtract(File file, Spectrum spec)
Performs the actual extraction.- Parameters:
file
- the current filespec
- the current spectrum- Returns:
- the extracted sample ID
-
extract
public String extract(File file, Spectrum spec)
Performs the extraction.- Specified by:
extract
in interfaceSampleIDExtraction
- Parameters:
file
- the current filespec
- the current spectrum- Returns:
- the extracted sample ID
-
-