Chromosome::GaDynamicOperationChromosome Class Reference

This class should be base for chromosomes which use extern genetic operations. More...

#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 >.

List of all members.

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.


Detailed Description

This class should be base for chromosomes which use extern genetic operations.

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.


Constructor & Destructor Documentation

Chromosome::GaDynamicOperationChromosome::GaDynamicOperationChromosome ( GaChromosomeOperationsBlock configBlock  )  [inline]

This constructor initializes chromosome with CCB.

Parameters:
configBlock pointer to CCB.

Chromosome::GaDynamicOperationChromosome::GaDynamicOperationChromosome ( const GaDynamicOperationChromosome c,
bool  setupOnly 
) [inline]

Copy constructor.

Parameters:
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.


Member Function Documentation

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.


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

Genetic Algorithm Library
Coolsoft Software Development