The new libga

Apart from big changes in the src/ga dir, and the addition of the src/do dir
it also generated a few changes here and there, e.g. some include file still
missing. Also removed some warning from some test files.
This commit is contained in:
evomarc 2001-04-24 04:52:04 +00:00
commit 56c9464306
32 changed files with 1679 additions and 158 deletions

View file

@ -44,30 +44,4 @@ template<class EOT> class eoEvalFunc : public eoUF<EOT&, void>
typedef typename EOT::Fitness EOFitT;
};
/**
Counts the number of evaluations actually performed, thus checks first
if it has to evaluate.. etc.
*/
#include <utils/eoParam.h>
template<class EOT> class eoEvalFuncCounter : public eoEvalFunc<EOT>, public eoValueParam<unsigned long>
{
public :
eoEvalFuncCounter(eoEvalFunc<EOT>& _func, std::string _name = "Eval. ")
: eoValueParam<unsigned long>(0, _name), func(_func) {}
virtual void operator()(EOT& _eo)
{
if (_eo.invalid())
{
value()++;
func(_eo);
}
}
private :
eoEvalFunc<EOT>& func;
};
#endif