Population::CouplingOperations::GaMulitpleCrossoverCouplingParams Class Reference

This class should be used (directly or by inheritance) by coupling operations which produce more then one child per parent pair before it chooses best child. More...

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

Inherits Population::GaCouplingParams.

List of all members.

Public Member Functions

 GaMulitpleCrossoverCouplingParams (int numberOfOffsprings, int offspringsPerParentPair)
 This constructor initializes parameters with user defined values.
 GaMulitpleCrossoverCouplingParams ()
 This constructor initializes parameters with default values. Default number of produced chromosome is 2, and coupling operation should produce one child per parent pair.
virtual GaParameters *GACALL Clone () const
 More details are given in specification of GaParameters::Clone method.
int GACALL GetOffspringsPerParentPair () const
 This method is not thread-safe.
void GACALL SetOffspringsPerParentPair (int number)
 SetOffspringsPerParentPair method sets number of chromosomes which are produced per one pair of parents.

Private Attributes

int _offspringsPerParentPair
 Number of chromosomes which are produced per one pair of parents.


Detailed Description

This class should be used (directly or by inheritance) by coupling operations which produce more then one child per parent pair before it chooses best child.

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

Population::CouplingOperations::GaMulitpleCrossoverCouplingParams::GaMulitpleCrossoverCouplingParams ( int  numberOfOffsprings,
int  offspringsPerParentPair 
) [inline]

This constructor initializes parameters with user defined values.

Parameters:
numberOfOffsprings number of chromosomes which should be produced.
offspringsPerParentPair number of chromosomes which are produced per one pair of parents.

Population::CouplingOperations::GaMulitpleCrossoverCouplingParams::GaMulitpleCrossoverCouplingParams (  )  [inline]

This constructor initializes parameters with default values. Default number of produced chromosome is 2, and coupling operation should produce one child per parent pair.


Member Function Documentation

virtual GaParameters* GACALL Population::CouplingOperations::GaMulitpleCrossoverCouplingParams::Clone (  )  const [inline, virtual]

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

This method is not thread-safe.

Reimplemented from Population::GaCouplingParams.

int GACALL Population::CouplingOperations::GaMulitpleCrossoverCouplingParams::GetOffspringsPerParentPair (  )  const [inline]

This method is not thread-safe.

Returns:
Method returns number of chromosomes which are produced per one pair of parents.

void GACALL Population::CouplingOperations::GaMulitpleCrossoverCouplingParams::SetOffspringsPerParentPair ( int  number  )  [inline]

SetOffspringsPerParentPair method sets number of chromosomes which are produced per one pair of parents.

This method is no thread-safe.

Parameters:
number number of chromosomes which are produced per one pair of parents.


Member Data Documentation

Number of chromosomes which are produced per one pair of parents.


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

Genetic Algorithm Library
Coolsoft Software Development