Package weka.filters
Class SimpleFilter
- java.lang.Object
-
- weka.filters.Filter
-
- weka.filters.SimpleFilter
-
- All Implemented Interfaces:
java.io.Serializable,CapabilitiesHandler,OptionHandler,RevisionHandler
- Direct Known Subclasses:
SimpleBatchFilter,SimpleStreamFilter
public abstract class SimpleFilter extends Filter implements OptionHandler
This filter contains common behavior of the SimpleBatchFilter and the SimpleStreamFilter.- Version:
- $Revision: 1.4 $
- Author:
- FracPete (fracpete at waikato dot ac dot nz)
- See Also:
SimpleBatchFilter,SimpleStreamFilter, Serialized Form
-
-
Constructor Summary
Constructors Constructor Description SimpleFilter()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description java.lang.StringdebugTipText()Returns the tip text for this propertybooleangetDebug()Returns the current debugging mode state.java.lang.String[]getOptions()Gets the current settings of the filter.abstract java.lang.StringglobalInfo()Returns a string describing this classifier.java.util.EnumerationlistOptions()Returns an enumeration describing the available options.voidsetDebug(boolean value)Sets the debugging modebooleansetInputFormat(Instances instanceInfo)Sets the format of the input instances.voidsetOptions(java.lang.String[] options)Parses a list of options for this object.-
Methods inherited from class weka.filters.Filter
batchFilterFile, batchFinished, filterFile, getCapabilities, getCapabilities, getOutputFormat, getRevision, input, isFirstBatchDone, isNewBatch, isOutputFormatDefined, main, makeCopies, makeCopy, numPendingOutput, output, outputPeek, toString, useFilter, wekaStaticWrapper
-
-
-
-
Method Detail
-
globalInfo
public abstract java.lang.String globalInfo()
Returns a string describing this classifier.- Returns:
- a description of the classifier suitable for displaying in the explorer/experimenter gui
-
listOptions
public java.util.Enumeration listOptions()
Returns an enumeration describing the available options.- Specified by:
listOptionsin interfaceOptionHandler- Returns:
- an enumeration of all the available options.
-
setOptions
public void setOptions(java.lang.String[] options) throws java.lang.ExceptionParses a list of options for this object. Also resets the state of the filter (this reset doesn't affect the options).- Specified by:
setOptionsin interfaceOptionHandler- Parameters:
options- the list of options as an array of strings- Throws:
java.lang.Exception- if an option is not supported- See Also:
reset()
-
getOptions
public java.lang.String[] getOptions()
Gets the current settings of the filter.- Specified by:
getOptionsin interfaceOptionHandler- Returns:
- an array of strings suitable for passing to setOptions
-
setDebug
public void setDebug(boolean value)
Sets the debugging mode- Parameters:
value- if true, debugging information is output
-
getDebug
public boolean getDebug()
Returns the current debugging mode state.- Returns:
- true if debugging mode is on
-
debugTipText
public java.lang.String debugTipText()
Returns the tip text for this property- Returns:
- tip text for this property suitable for displaying in the explorer/experimenter gui
-
setInputFormat
public boolean setInputFormat(Instances instanceInfo) throws java.lang.Exception
Sets the format of the input instances. Also resets the state of the filter (this reset doesn't affect the options).- Overrides:
setInputFormatin classFilter- Parameters:
instanceInfo- an Instances object containing the input instance structure (any instances contained in the object are ignored - only the structure is required).- Returns:
- true if the outputFormat may be collected immediately
- Throws:
java.lang.Exception- if the inputFormat can't be set successfully- See Also:
reset()
-
-