#include <D:/Temp/vs/gal/source/Chromosome.h>
Inherits Chromosome::GaDefaultChromosome.
Inherited by Chromosome::Representation::GaBinaryChromosome, Chromosome::Representation::GaDomainChromosome< T >, and Chromosome::Representation::GaDomainChromosome< TYPE >.
Public Member Functions | |
GaDynamicOperationChromosome (GaChromosomeOperationsBlock *configBlock) | |
This constructor initializes chromosome with CCB. | |
GaDynamicOperationChromosome (const GaDynamicOperationChromosome &c, bool setupOnly) | |
Copy constructor. | |
virtual GAL_API int GACALL | CompareFitnesses (float c) const |
CompareFitnesses method delegates control to extern fitness comparator specified in CCB. | |
Protected Member Functions | |
virtual GAL_API GaChromosomePtr GACALL | PerformCrossover (GaChromosomePtr secondParent) const |
PerformCrossover method delegates control to extern crossover operation specified in CCB. | |
virtual GAL_API void GACALL | PerformMutation () |
PerformMutation method delegates control to extern mutation operation specified in CCB. | |
virtual GAL_API float GACALL | CalculateFitness () const |
CalculateFitness method delegates control to extern fitness operation specified in CCB. |
This class has no built-in synchronizator, so LOCK_OBJECT
and LOCK_THIS_OBJECT
macros cannot be used with instances of this class. No public or private methods are thread-safe.
Chromosome::GaDynamicOperationChromosome::GaDynamicOperationChromosome | ( | GaChromosomeOperationsBlock * | configBlock | ) | [inline] |
This constructor initializes chromosome with CCB.
configBlock | pointer to CCB. |
Chromosome::GaDynamicOperationChromosome::GaDynamicOperationChromosome | ( | const GaDynamicOperationChromosome & | c, | |
bool | setupOnly | |||
) | [inline] |
Copy constructor.
c | reference to chromosome which is copied. | |
setupOnly | if this parameter is true , only pointer to CCB is copied. If this parameter is false , chromosome's data and CCB is copied. |
int Chromosome::GaDynamicOperationChromosome::CompareFitnesses | ( | float | c | ) | const [virtual] |
CompareFitnesses method delegates control to extern fitness comparator specified in CCB.
For more information see specification of GaChromosome::CompareFitnesses method.
This method is not thread-safe.
Implements Chromosome::GaDefaultChromosome.
GaChromosomePtr Chromosome::GaDynamicOperationChromosome::PerformCrossover | ( | GaChromosomePtr | secondParent | ) | const [protected, virtual] |
PerformCrossover
method delegates control to extern crossover operation specified in CCB.
For more information see specification of GaDefaultChromosome::PerformCrossover method.
This method is not thread-safe.
Implements Chromosome::GaDefaultChromosome.
void Chromosome::GaDynamicOperationChromosome::PerformMutation | ( | ) | [protected, virtual] |
PerformMutation
method delegates control to extern mutation operation specified in CCB.
For more information see specification of GaDefaultChromosome::PerformMutation method.
This method is not thread-safe.
Implements Chromosome::GaDefaultChromosome.
float Chromosome::GaDynamicOperationChromosome::CalculateFitness | ( | ) | const [protected, virtual] |
CalculateFitness
method delegates control to extern fitness operation specified in CCB.
For more information see specification of GaDefaultChromosome::CalculateFitness method.
This method is not thread-safe.
Implements Chromosome::GaChromosome.