eoScalarFitness< ScalarType, Compare > Class Template Reference

eoScalarFitness<ScalarType, Compare = less<ScalarType> >: Wraps a scalar fitness values such as a double or int, with the option of maximizing (using less<ScalarType>) or minimizing (using greater<ScalarType>) More...

#include <eoScalarFitness.h>

List of all members.

Public Member Functions

 eoScalarFitness (const eoScalarFitness &other)
 eoScalarFitness (const ScalarType &v)
eoScalarFitnessoperator= (const eoScalarFitness &other)
eoScalarFitnessoperator= (const ScalarType &v)
 operator ScalarType (void) const
bool operator< (const eoScalarFitness &other) const
 Comparison, using less by default.
bool operator< (const ScalarType &other) const
 Comparison, using less by default.
bool operator> (const eoScalarFitness< ScalarType, Compare > &y) const
bool operator<= (const eoScalarFitness< ScalarType, Compare > &y) const
bool operator>= (const eoScalarFitness< ScalarType, Compare > &y) const

Private Attributes

ScalarType value


Detailed Description

template<class ScalarType, class Compare>
class eoScalarFitness< ScalarType, Compare >

eoScalarFitness<ScalarType, Compare = less<ScalarType> >: Wraps a scalar fitness values such as a double or int, with the option of maximizing (using less<ScalarType>) or minimizing (using greater<ScalarType>)

It overrides operator<() to use the Compare template argument

Suitable constructors and assignments and casts are defined to work with this quantity as if it were a ScalarType.

Definition at line 43 of file eoScalarFitness.h.


The documentation for this class was generated from the following file:

Generated on Thu Jan 1 23:19:50 2009 for EvolvingObjects by  doxygen 1.5.5