com.epochx.life
Interface LifeCycleListener<TYPE>
- All Superinterfaces:
- CrossoverListener<TYPE>, ElitismListener<TYPE>, GenerationListener, InitialisationListener<TYPE>, MutationListener<TYPE>, PoolSelectionListener<TYPE>, ReproductionListener<TYPE>, TerminationListener
- All Known Implementing Classes:
- CubicRegression, Even4Parity, Even5Parity, Even7Parity, GPAbstractModel, Majority5, Majority9, Multiplexer11Bit, Multiplexer20Bit, Multiplexer37Bit, Multiplexer6Bit, QuarticRegression, SantaFeTrail
public interface LifeCycleListener<TYPE>
- extends CrossoverListener<TYPE>, ElitismListener<TYPE>, GenerationListener, InitialisationListener<TYPE>, MutationListener<TYPE>, PoolSelectionListener<TYPE>, ReproductionListener<TYPE>, TerminationListener
Implementations of LifeCycleListener can be used to listen for events
throughout the life of a GE run. The provided methods will be called at the
relevant times during execution, and have the opportunity to confirm the
operation by returning the appropriate argument value, modify the operation
by altering the argument before returning and in some cases it is possible
to trigger a 'reversion' by returning null. A reversion is where the
operation is discarded and rerun. In the case of reversion, the life cycle
method will be recalled in the same way during the rerun, allowing the life
cycle listener the ability to revert indefinitely. It is worth noting that
this leaves room for the potential of an infinite loop if any of these
methods were defined to return null in all possible circumstances. The
number of reversions for crossover and mutation is obtainable from the
crossover stats and mutation stats respectively.