Class InstrumentedAlgorithm<T extends Algorithm>
java.lang.Object
org.moeaframework.algorithm.extension.AlgorithmWrapper<T>
org.moeaframework.analysis.runtime.InstrumentedAlgorithm<T>
- Type Parameters:
- T- the type of the algorithm
- All Implemented Interfaces:
- Algorithm,- Extensible,- Configurable,- Named,- Stateful
Wraps an algorithm to indicate it is instrumented to collect runtime data.
- 
Constructor SummaryConstructorsConstructorDescriptionInstrumentedAlgorithm(T algorithm) Wraps the given algorithm to create an instrumented version.
- 
Method SummaryModifier and TypeMethodDescriptionvoidaddCollector(Collector collector) Adds a collector to this instrumented algorithm.Returns the collected runtime data as a result series.registerExtension(Frequency frequency) Registers the extension with the algorithm if one does not already exist.Methods inherited from class org.moeaframework.algorithm.extension.AlgorithmWrapperevaluate, getAlgorithm, getExtensions, getName, getNumberOfEvaluations, getProblem, getResult, initialize, isInitialized, isTerminated, loadState, saveState, step, terminateMethods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.moeaframework.algorithm.AlgorithmevaluateAll, evaluateAll, run, runMethods inherited from interface org.moeaframework.core.configuration.ConfigurableapplyConfiguration, getConfigurationMethods inherited from interface org.moeaframework.algorithm.extension.ExtensibleaddExtension, removeExtension
- 
Constructor Details- 
InstrumentedAlgorithmWraps the given algorithm to create an instrumented version.- Parameters:
- algorithm- the algorithm
 
 
- 
- 
Method Details- 
registerExtensionRegisters the extension with the algorithm if one does not already exist.- Parameters:
- frequency- the frequency
- Returns:
- the extension
 
- 
addCollectorAdds a collector to this instrumented algorithm. The collector should have already been attached to the algorithm.- Parameters:
- collector- the collector
 
- 
getSeriesReturns the collected runtime data as a result series. Each result entry contains the approximation set fromAlgorithm.getResult()along with any properties stored by the collectors.- Returns:
- the result series
 
 
-