
MOEA Framework 2.12 API Specification 

PREV CLASS NEXT CLASS  FRAMES NO FRAMES  
SUMMARY: NESTED  FIELD  CONSTR  METHOD  DETAIL: FIELD  CONSTR  METHOD 
java.lang.Object org.moeaframework.algorithm.PeriodicAction org.moeaframework.analysis.collector.InstrumentedAlgorithm
public class InstrumentedAlgorithm
Decorates an algorithm to periodically collect information about its runtime
behavior. The NFE
field is automatically recorded by this class.
Nested Class Summary 

Nested classes/interfaces inherited from class org.moeaframework.algorithm.PeriodicAction 

PeriodicAction.FrequencyType 
Field Summary 

Fields inherited from class org.moeaframework.algorithm.PeriodicAction 

algorithm, frequency, frequencyType, iteration, lastInvocation 
Constructor Summary  

InstrumentedAlgorithm(Algorithm algorithm,
int frequency)
Decorates the specified algorithm to periodically collect information about its runtime behavior. 

InstrumentedAlgorithm(Algorithm algorithm,
int frequency,
PeriodicAction.FrequencyType frequencyType)
Decorates the specified algorithm to periodically collect information about its runtime behavior. 
Method Summary  

void 
addCollector(Collector collector)
Adds a collector to this instrumented algorithm. 
void 
doAction()
Invoked periodically by this class to perform some function. 
Accumulator 
getAccumulator()
Returns the accumulator to which all recorded information is stored. 
Serializable 
getState()
Returns a Serializable object representing the internal state of
this algorithm. 
void 
setState(Object objState)
Sets the internal state of of this algorithm. 
Methods inherited from class org.moeaframework.algorithm.PeriodicAction 

evaluate, getNumberOfEvaluations, getProblem, getResult, isTerminated, step, terminate 
Methods inherited from class java.lang.Object 

clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait 
Constructor Detail 

public InstrumentedAlgorithm(Algorithm algorithm, int frequency)
algorithm
 the algorithm to decoratefrequency
 the frequency, in evaluations, that data is collectedpublic InstrumentedAlgorithm(Algorithm algorithm, int frequency, PeriodicAction.FrequencyType frequencyType)
algorithm
 the algorithm to decoratefrequency
 the frequency that data is collectedfrequencyType
 if frequency is defined by EVALUATIONS or STEPSMethod Detail 

public void addCollector(Collector collector)
collector
 the collectorpublic Accumulator getAccumulator()
public void doAction()
PeriodicAction
doAction
in class PeriodicAction
public Serializable getState() throws NotSerializableException
Algorithm
Serializable
object representing the internal state of
this algorithm.
getState
in interface Algorithm
getState
in class PeriodicAction
Serializable
object representing the internal state of
this algorithm
NotSerializableException
 if this algorithm does not support
serializationpublic void setState(Object objState) throws NotSerializableException
Algorithm
setState
in interface Algorithm
setState
in class PeriodicAction
objState
 the internal state of this algorithm
NotSerializableException
 if this algorithm does not support
serialization

MOEA Framework 2.12 API Specification 

PREV CLASS NEXT CLASS  FRAMES NO FRAMES  
SUMMARY: NESTED  FIELD  CONSTR  METHOD  DETAIL: FIELD  CONSTR  METHOD 