Package moa.options
Class AbstractOptionHandler
- java.lang.Object
-
- moa.AbstractMOAObject
-
- moa.options.AbstractOptionHandler
-
- All Implemented Interfaces:
Configurable
,Serializable
,MOAObject
,OptionHandler
- Direct Known Subclasses:
AbstractAnomalyDetector
,AbstractChangeDetector
,AbstractClassifier
,AbstractClusterer
,AbstractConceptDriftGenerator
,AbstractFeatureRanking
,AbstractMultiLabelErrorMeasurer
,AbstractMultiLabelStreamFilter
,AbstractStreamFilter
,AbstractTask
,AgrawalGenerator
,ArffFileStream
,AssetNegotiationGenerator
,BaselinePredictor
,BasicAUCImbalancedPerformanceEvaluator
,BasicClassificationPerformanceEvaluator
,BinaryTreeNumericAttributeClassObserver
,BinaryTreeNumericAttributeClassObserverRegression
,BootstrappedStream
,BRISMFPredictor
,CantellisInequality
,ChebyshevInequality
,ClusteringStream
,ConceptDriftRealStream
,ConceptDriftStream
,Cramer
,EntropyThreshold
,FilteredStream
,FixedBM
,FlixsterDataset
,GaussianNumericAttributeClassObserver
,GaussInequality
,GiniSplitCriterion
,GreenwaldKhannaNumericAttributeClassObserver
,HyperplaneGenerator
,ICVarianceReduction
,ImbalancedStream
,InfoGainSplitCriterion
,IrrelevantFeatureAppenderStream
,JesterDataset
,KNN
,LearningLiteral
,LEDGenerator
,MemRecommenderData
,MeritThreshold
,MetaMultilabelGenerator
,MixedGenerator
,MovielensDataset
,MultiFilteredStream
,MultiLabelBSTree
,MultiLabelBSTreeFloat
,MultiLabelBSTreePCT
,MultiLabelFilteredStream
,MultilabelInformationGain
,MultiLabelNominalAttributeObserver
,MultiTargetArffFileStream
,MultiTargetVarianceRatio
,MultiTargetWindowRegressionPerformanceEvaluator
,MultiTargetWindowRegressionPerformanceRelativeMeasuresEvaluator
,NominalAttributeClassObserver
,NullAttributeClassObserver
,PartitioningStream
,RandomRBFGenerator
,RandomTreeGenerator
,SEAGenerator
,SelectAllInputs
,SelectAllOutputs
,SineGenerator
,STAGGERGenerator
,StdDevThreshold
,TextGenerator
,VarianceRatioSplitCriterion
,VarianceReductionSplitCriterion
,VarianceThreshold
,VFMLNumericAttributeClassObserver
,WaveformGenerator
,WindowAUCImbalancedPerformanceEvaluator
,WindowRegressionPerformanceEvaluator
public abstract class AbstractOptionHandler extends AbstractMOAObject implements OptionHandler
Abstract Option Handler. All classes that have options in MOA extend this class.- Version:
- $Revision: 7 $
- Author:
- Richard Kirkby (rkirkby@cs.waikato.ac.nz)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected OptionsHandler
config
-
Constructor Summary
Constructors Constructor Description AbstractOptionHandler()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description OptionHandler
copy()
This method produces a copy of this object.String
getCLICreationString(Class<?> expectedType)
Gets the Command Line Interface text to create the objectOptions
getOptions()
Gets the options of this objectprotected Object
getPreparedClassOption(ClassOption opt)
Gets a prepared option of this class.String
getPurposeString()
Dictionary with option texts and objectsprotected void
prepareClassOptions(TaskMonitor monitor, ObjectRepository repository)
Prepares the options of this class.void
prepareForUse()
This method prepares this object for use.void
prepareForUse(TaskMonitor monitor, ObjectRepository repository)
This method prepares this object for use.protected abstract void
prepareForUseImpl(TaskMonitor monitor, ObjectRepository repository)
This method describes the implementation of how to prepare this object for use.-
Methods inherited from class moa.AbstractMOAObject
copy, measureByteSize, measureByteSize, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface moa.MOAObject
getDescription, measureByteSize
-
-
-
-
Field Detail
-
config
protected OptionsHandler config
-
-
Method Detail
-
getPurposeString
public String getPurposeString()
Dictionary with option texts and objects- Specified by:
getPurposeString
in interfaceOptionHandler
- Returns:
- the string with the purpose of this object
-
getOptions
public Options getOptions()
Description copied from interface:OptionHandler
Gets the options of this object- Specified by:
getOptions
in interfaceOptionHandler
- Returns:
- the options of this object
-
prepareForUse
public void prepareForUse()
Description copied from interface:OptionHandler
This method prepares this object for use.- Specified by:
prepareForUse
in interfaceOptionHandler
-
prepareForUse
public void prepareForUse(TaskMonitor monitor, ObjectRepository repository)
Description copied from interface:OptionHandler
This method prepares this object for use.- Specified by:
prepareForUse
in interfaceOptionHandler
- Parameters:
monitor
- the TaskMonitor to userepository
- the ObjectRepository to use
-
prepareForUseImpl
protected abstract void prepareForUseImpl(TaskMonitor monitor, ObjectRepository repository)
This method describes the implementation of how to prepare this object for use. All classes that extends this class have to implementprepareForUseImpl
and notprepareForUse
sinceprepareForUse
callsprepareForUseImpl
.- Parameters:
monitor
- the TaskMonitor to userepository
- the ObjectRepository to use
-
getCLICreationString
public String getCLICreationString(Class<?> expectedType)
Description copied from interface:OptionHandler
Gets the Command Line Interface text to create the object- Specified by:
getCLICreationString
in interfaceOptionHandler
- Returns:
- the Command Line Interface text to create the object
-
copy
public OptionHandler copy()
Description copied from interface:MOAObject
This method produces a copy of this object.- Specified by:
copy
in interfaceMOAObject
- Specified by:
copy
in interfaceOptionHandler
- Overrides:
copy
in classAbstractMOAObject
- Returns:
- a copy of this object
-
prepareClassOptions
protected void prepareClassOptions(TaskMonitor monitor, ObjectRepository repository)
Prepares the options of this class.- Parameters:
monitor
- the TaskMonitor to userepository
- the ObjectRepository to use
-
getPreparedClassOption
protected Object getPreparedClassOption(ClassOption opt)
Gets a prepared option of this class.- Parameters:
opt
- the class option to get- Returns:
- an option stored in the dictionary
-
-