程序包 weka.experiment
接口 ResultListener
- 所有超级接口:
Serializable
- 所有已知实现类:
AveragingResultProducer
,CSVResultListener
,DatabaseResultListener
,DatabaseResultProducer
,InstancesResultListener
,LearningRateResultProducer
Interface for objects able to listen for results obtained
by a ResultProducer
- 版本:
- $Revision: 1.7 $
- 作者:
- Len Trigg (trigg@cs.waikato.ac.nz)
-
方法概要
修饰符和类型方法说明void
acceptResult
(ResultProducer rp, Object[] key, Object[] result) Accepts results from a ResultProducer.String[]
Determines if there are any constraints (imposed by the destination) on additional result columns to be produced by resultProducers.boolean
isResultRequired
(ResultProducer rp, Object[] key) Determines whether the results for a specified key must be generated.void
Perform any postprocessing.void
Prepare for the results to be received.
-
方法详细资料
-
determineColumnConstraints
Determines if there are any constraints (imposed by the destination) on additional result columns to be produced by resultProducers. Null should be returned if there are NO constraints, otherwise a list of column names should be returned as an array of Strings.- 参数:
rp
- the ResultProducer to which the constraints will apply- 返回:
- an array of column names to which resutltProducer's additional results will be restricted.
- 抛出:
Exception
- if an error occurs
-
preProcess
Prepare for the results to be received.- 参数:
rp
- the ResultProducer that will generate the results- 抛出:
Exception
- if an error occurs during preprocessing.
-
postProcess
Perform any postprocessing. When this method is called, it indicates that no more results will be sent that need to be grouped together in any way.- 参数:
rp
- the ResultProducer that generated the results- 抛出:
Exception
- if an error occurs
-
acceptResult
Accepts results from a ResultProducer.- 参数:
rp
- the ResultProducer that generated the resultskey
- an array of Objects (Strings or Doubles) that uniquely identify a result for a given ResultProducer with given compatibilityStateresult
- the results stored in an array. The objects stored in the array may be Strings, Doubles, or null (for the missing value).- 抛出:
Exception
- if the result could not be accepted.
-
isResultRequired
Determines whether the results for a specified key must be generated.- 参数:
rp
- the ResultProducer wanting to generate the resultskey
- an array of Objects (Strings or Doubles) that uniquely identify a result for a given ResultProducer with given compatibilityState- 返回:
- true if the result should be generated
- 抛出:
Exception
- if it could not be determined if the result is needed.
-