Extract several methods from optimizers into a new AbstractOptimizationProblem
Methods like:
/**
* This method allows you to add a listener to the Optimizer.
*
* @param ea
*/
void addPopulationChangedEventListener(InterfacePopulationChangedEventListener ea);
/**
* This method removes a listener from the Optimizer. It returns true on success,
* false if the listener could not be found.
*
* @param ea
*/
boolean removePopulationChangedEventListener(InterfacePopulationChangedEventListener ea);
/**
* Assuming that all optimizer will store their data in a population
* we will allow access to this population to query to current state
* of the optimizer.
*
* @return The population of current solutions to a given problem.
*/
Population getPopulation();
void setPopulation(Population pop);
/**
* This method will set the problem that is to be optimized. The problem
* should be initialized when this method is called.
*
* @param problem The optimization problem.
*/
void setProblem(InterfaceOptimizationProblem problem);
InterfaceOptimizationProblem getProblem();
don't make any sense to be implemented repeatedly by all Optimizers. They should live in a new AbstractOptimizationProblem class.