Algorithm::StopCriterias::GaGenerationCriteriaParams Class Reference

GaGenerationCriteriaParams class is used by GaGenerationCriteria class as parameters for the criteria. It contains number of generation after which execution of algorithm should be stopped. More...

#include <D:/Temp/vs/gal/source/StopCriterias.h>

Inherits Algorithm::GaStopCriteriaParams.

List of all members.

Public Member Functions

 GaGenerationCriteriaParams (int numberOfGeneration)
 This constructor initializes parameters with user-defined number of generations.
 GaGenerationCriteriaParams ()
 This constructor initializes parameters with default values. Default number of generations is 1000.
virtual GaParameters *GACALL Clone () const
 More details are given in specification of GaParameters::Clone method.
int GACALL GetNumberOfGeneration () const
 This method is not thread-safe.
void GACALL SetNumberOfGeneration (int number)
 SetNumberOfGeneration method sets number of generations after which algorithm should stops its execution.

Private Attributes

int _numberOfGenerations
 Number of generations after which algorithm should stops its execution.


Detailed Description

GaGenerationCriteriaParams class is used by GaGenerationCriteria class as parameters for the criteria. It contains number of generation after which execution of algorithm should be stopped.

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

Algorithm::StopCriterias::GaGenerationCriteriaParams::GaGenerationCriteriaParams ( int  numberOfGeneration  )  [inline]

This constructor initializes parameters with user-defined number of generations.

Parameters:
numberOfGeneration number of generations after which algorithm should stops its execution.

Algorithm::StopCriterias::GaGenerationCriteriaParams::GaGenerationCriteriaParams (  )  [inline]

This constructor initializes parameters with default values. Default number of generations is 1000.


Member Function Documentation

virtual GaParameters* GACALL Algorithm::StopCriterias::GaGenerationCriteriaParams::Clone (  )  const [inline, virtual]

More details are given in specification of GaParameters::Clone method.

Implements Common::GaParameters.

int GACALL Algorithm::StopCriterias::GaGenerationCriteriaParams::GetNumberOfGeneration (  )  const [inline]

This method is not thread-safe.

Returns:
Method returns number of generations after which algorithm should stops its execution.

void GACALL Algorithm::StopCriterias::GaGenerationCriteriaParams::SetNumberOfGeneration ( int  number  )  [inline]

SetNumberOfGeneration method sets number of generations after which algorithm should stops its execution.

This method is not thread-safe.

Parameters:
number number of generations.


Member Data Documentation

Number of generations after which algorithm should stops its execution.


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

Genetic Algorithm Library
Coolsoft Software Development